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

Diff for /src/usr.bin/ssh/clientloop.c between version 1.261 and 1.262

version 1.261, 2014/07/15 15:54:14 version 1.262, 2015/01/14 20:05:27
Line 102 
Line 102 
 #include "match.h"  #include "match.h"
 #include "msg.h"  #include "msg.h"
 #include "roaming.h"  #include "roaming.h"
   #include "ssherr.h"
   
 /* import options */  /* import options */
 extern Options options;  extern Options options;
Line 1770 
Line 1771 
 client_input_agent_open(int type, u_int32_t seq, void *ctxt)  client_input_agent_open(int type, u_int32_t seq, void *ctxt)
 {  {
         Channel *c = NULL;          Channel *c = NULL;
         int remote_id, sock;          int r, remote_id, sock;
   
         /* Read the remote channel number from the message. */          /* Read the remote channel number from the message. */
         remote_id = packet_get_int();          remote_id = packet_get_int();
Line 1780 
Line 1781 
          * Get a connection to the local authentication agent (this may again           * Get a connection to the local authentication agent (this may again
          * get forwarded).           * get forwarded).
          */           */
         sock = ssh_get_authentication_socket();          if ((r = ssh_get_authentication_socket(&sock)) != 0 &&
               r != SSH_ERR_AGENT_NOT_PRESENT)
                   debug("%s: ssh_get_authentication_socket: %s",
                       __func__, ssh_err(r));
   
   
         /*          /*
          * If we could not connect the agent, send an error message back to           * If we could not connect the agent, send an error message back to
          * the server. This should never happen unless the agent dies,           * the server. This should never happen unless the agent dies,
Line 1898 
Line 1903 
 client_request_agent(const char *request_type, int rchan)  client_request_agent(const char *request_type, int rchan)
 {  {
         Channel *c = NULL;          Channel *c = NULL;
         int sock;          int r, sock;
   
         if (!options.forward_agent) {          if (!options.forward_agent) {
                 error("Warning: ssh server tried agent forwarding.");                  error("Warning: ssh server tried agent forwarding.");
Line 1906 
Line 1911 
                     "malicious server.");                      "malicious server.");
                 return NULL;                  return NULL;
         }          }
         sock = ssh_get_authentication_socket();          if ((r = ssh_get_authentication_socket(&sock)) != 0) {
         if (sock < 0)                  if (r != SSH_ERR_AGENT_NOT_PRESENT)
                           debug("%s: ssh_get_authentication_socket: %s",
                               __func__, ssh_err(r));
                 return NULL;                  return NULL;
           }
         c = channel_new("authentication agent connection",          c = channel_new("authentication agent connection",
             SSH_CHANNEL_OPEN, sock, sock, -1,              SSH_CHANNEL_OPEN, sock, sock, -1,
             CHAN_X11_WINDOW_DEFAULT, CHAN_TCP_PACKET_DEFAULT, 0,              CHAN_X11_WINDOW_DEFAULT, CHAN_TCP_PACKET_DEFAULT, 0,

Legend:
Removed from v.1.261  
changed lines
  Added in v.1.262