Subject: ctlinnd addhist breakage: Solaris 2.5/INN 1.5[.1]

From: [email-masked] (Larry Rosenman)
Date: Tue, 8 Apr 1997 02:53:34 GMT

-----BEGIN PGP SIGNED MESSAGE-----

[mailed to [email-masked] as well]

I have had an unstable news server for a number of weeks, so I decided to
run makehistory -b -u -n -v.  I would come back after it running for >1 day
to find it hung in a poll() for the response to a ICC_ADDHIST command. 

Investigating further, I found a CCreader: short read error. 
Looking into it, I found that cc.c uses a BUFSIZ buffer to read the packet.

Unfortunately, this is 1024 on Solaris 2.5[.1].  With the massive cross-posting
in some groups, and the large group+Message-ID names, 1K ain't close enough
for some articles. 

James: Mayhaps this should be configurable?

I made the following patch which SEEMS to fix it.

Let me know if I screwed anything else up.  This is against
1.5, but cc.c hasn't changed from 1.5 -> 1.5.1

Larry

*** old/cc.c	Mon Apr  7 21:11:34 1997
- --- cc.c	Mon Apr  7 21:16:47 1997
***************
*** 1576,1583 ****
      int			written;
  #endif	/* defined(DO_HAVE_UNIX_DOMAIN) */
      int			i;
!     char		buff[BUFSIZ + 2];
!     char		copy[BUFSIZ + 2];
      char		*argv[SC_MAXFIELDS + 2];
      int			argc;
      int			len;
- --- 1576,1583 ----
      int			written;
  #endif	/* defined(DO_HAVE_UNIX_DOMAIN) */
      int			i;
!     char		buff[BIG_BUFFER + 2];
!     char		copy[BIG_BUFFER + 2];
      char		*argv[SC_MAXFIELDS + 2];
      int			argc;
      int			len;
***************
*** 1591,1597 ****
  
  #if defined (DO_HAVE_UNIX_DOMAIN)
      
!     i = RECVorREAD(CCchan->fd, buff, BUFSIZ) ;
      if (i < 0) {
  	syslog(L_ERROR, "%s cant recv CCreader %m", LogName);
  	return;
- --- 1591,1597 ----
  
  #if defined (DO_HAVE_UNIX_DOMAIN)
      
!     i = RECVorREAD(CCchan->fd, buff, BIG_BUFFER) ;
      if (i < 0) {
  	syslog(L_ERROR, "%s cant recv CCreader %m", LogName);
  	return;

-- 
Larry Rosenman                      http://www.lerctr.org/~ler
Phone: +1 972-399-0210 (voice) Internet: [email-masked]
US Mail: 900 Lake Isle Circle, Irving, TX 75060-7726