[BACK]Return to telnet.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / telnet

Diff for /src/usr.bin/telnet/telnet.c between version 1.19 and 1.20

version 1.19, 2005/02/27 15:46:42 version 1.20, 2009/04/28 06:46:03
Line 1516 
Line 1516 
 {  {
         unsigned char *p;          unsigned char *p;
   
         if (opt_reply) {          p = (unsigned char *)realloc(opt_reply, OPT_REPLY_SIZE);
                 p = (unsigned char *)realloc(opt_reply, OPT_REPLY_SIZE);          if (p == NULL)
                 if (p == NULL)                  free(opt_reply);
                         free(opt_reply);  
         } else  
                 p = (unsigned char *)malloc(OPT_REPLY_SIZE);  
         opt_reply = p;          opt_reply = p;
         if (opt_reply == NULL) {          if (opt_reply == NULL) {
 /*@*/           printf("env_opt_start: malloc()/realloc() failed!!!\n");  /*@*/           printf("env_opt_start: realloc() failed!!!\n");
                 opt_reply = opt_replyp = opt_replyend = NULL;                  opt_reply = opt_replyp = opt_replyend = NULL;
                 return;                  return;
         }          }
Line 2190 
Line 2187 
 telnet(user)  telnet(user)
     char *user;      char *user;
 {  {
     int printed_encrypt = 0;  
   
     sys_telnet_init();      sys_telnet_init();
   
 #if     defined(AUTHENTICATION) || defined(ENCRYPTION)  #if     defined(AUTHENTICATION) || defined(ENCRYPTION)
Line 2240 
Line 2235 
     if (wantencryption) {      if (wantencryption) {
         extern int auth_has_failed;          extern int auth_has_failed;
         time_t timeout = time(0) + 60;          time_t timeout = time(0) + 60;
           int printed_encrypt = 0;
   
         send_do(TELOPT_ENCRYPT, 1);          send_do(TELOPT_ENCRYPT, 1);
         send_will(TELOPT_ENCRYPT, 1);          send_will(TELOPT_ENCRYPT, 1);

Legend:
Removed from v.1.19  
changed lines
  Added in v.1.20