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

Diff for /src/usr.bin/ssh/canohost.c between version 1.40 and 1.41

version 1.40, 2004/06/21 17:36:31 version 1.41, 2004/07/21 11:51:29
Line 339 
Line 339 
 int  int
 get_remote_port(void)  get_remote_port(void)
 {  {
         return get_port(0);          static int port = -1;
   
           /* Cache to avoid getpeername() on a dead connection */
           if (port == -1)
                   port = get_port(0);
   
           return port;
 }  }
   
 int  int

Legend:
Removed from v.1.40  
changed lines
  Added in v.1.41