[2033] in Kerberos-V5-bugs

home help back first fref pref prev next nref lref last post

Re: one further patch for telnetd under AIX 4.1.4

daemon@ATHENA.MIT.EDU (Jason Wessel)
Sun Jun 23 15:01:31 1996

To: hartmans@MIT.EDU (Sam Hartman)
Date: Sun, 23 Jun 1996 13:59:41 -0500 (CDT)
Cc: p-pomes@alfalfa.aiss.uiuc.edu, DEEngert@anl.gov, kerberos@MIT.EDU,
        krb5-bugs@MIT.EDU, jwessel@uiuc.edu, lemson@uiuc.edu, roma@uiuc.edu,
        cc@austin.ibm.com
In-Reply-To: <tslbuiceke6.fsf@tertius.mit.edu> from "Sam Hartman" at Jun 21, 96 08:45:53 pm
Reply-To: jwessel@uiuc.edu (Jason Wessel)
From: "Jason Wessel" <jwessel@uiuc.edu>



----Sam Hartman previously wrote----
> 	What does this patch do if it's not obvious groveling through
> the suboption code?  (I am not too familiar with state.c.)  Also, why
> should it be done on AIX?  I.E.  Does your patch work for a well-known
> reason, or just because it changes things  enough?
> 
>  doesn't matter too much, although I like to try and understand
> problems.
> 
> --Sam
> 


That patch does the "correct" option negotiation for AIX. RS6k's are kinda
werid in that respect. Below is a patch to fix the "stty raw" problem,
which I derived from my modifications to the beta4 code, which we
are still using in a production mode here at the U of I. If there is
interest, I can post the diffs to the telnetd from the beta4 source.

Also if someone could tell me what defines I can put in the code that
gnu autoconfigure will find for AIX 4.x I would be most appreciative :)


-- 
Jason Wessel  <jwessel@uiuc.edu> - CCSO Systems Team Engineer
WWW Homepage <A HREF="http://www.uiuc.edu/ph/www/jwessel">Jason Wessel</A>


-----------Cut HERE------------
*** telnetd.c	Wed May  1 20:22:39 1996
--- telnetd.c.good	Sun Jun 23 13:43:49 1996
***************
*** 1053,1059 ****
--- 1053,1061 ----
  	send_will(TELOPT_STATUS, 1);
  	flowmode = 1;		/* default flow control state */
  	restartany = -1;	/* uninitialized... */
+ #ifndef AIX4
  	send_do(TELOPT_LFLOW, 1);
+ #endif
  
  	/*
  	 * Spin, waiting for a response from the DO ECHO.  However,
***************
*** 1108,1113 ****
--- 1110,1116 ----
  	if (my_state_is_wont(TELOPT_ECHO))
  		send_will(TELOPT_ECHO, 1);
  
+ #ifndef AIX4
  #ifndef	STREAMSPTY
  	/*
  	 * Turn on packet mode
***************
*** 1114,1119 ****
--- 1117,1123 ----
  	 */
  	(void) ioctl(p, TIOCPKT, (char *)&on);
  #endif
+ #endif
  
  #if	defined(LINEMODE) && defined(KLUDGELINEMODE)
  	/*
***************
*** 1365,1370 ****
--- 1369,1386 ----
  #else
  			pcc = readstream(p, ptyibuf, BUFSIZ);
  #endif
+ #ifdef AIX4
+                         if (pcc < 0 && errno == EWOULDBLOCK)
+                                 pcc = 0;
+                         else {
+                                 if (pcc <= 0)
+                                         break;
+                                 ptyip = ptyibuf;
+                         }
+                 }
+ 
+ #else  /* AIX4 */
+ 
  			/*
  			 * On some systems, if we try to read something
  			 * off the master side before the slave side is
***************
*** 1434,1440 ****
  #endif	/* defined(CRAY2) && defined(UNICOS5) */
  			}
  		}
! 
  		while (pcc > 0) {
  			if ((&netobuf[BUFSIZ] - nfrontp) < 2)
  				break;
--- 1450,1456 ----
  #endif	/* defined(CRAY2) && defined(UNICOS5) */
  			}
  		}
! #endif /* AIX4 */
  		while (pcc > 0) {
  			if ((&netobuf[BUFSIZ] - nfrontp) < 2)
  				break;

home help back first fref pref prev next nref lref last post