[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.249 and 1.250

version 1.249, 2013/05/16 02:00:34 version 1.250, 2013/05/17 00:13:13
Line 385 
Line 385 
                 unlink(xauthfile);                  unlink(xauthfile);
                 rmdir(xauthdir);                  rmdir(xauthdir);
         }          }
         if (xauthdir)          free(xauthdir);
                 xfree(xauthdir);          free(xauthfile);
         if (xauthfile)  
                 xfree(xauthfile);  
   
         /*          /*
          * If we didn't get authentication data, just make up some           * If we didn't get authentication data, just make up some
Line 544 
Line 542 
         if (--gc->ref_count <= 0) {          if (--gc->ref_count <= 0) {
                 TAILQ_REMOVE(&global_confirms, gc, entry);                  TAILQ_REMOVE(&global_confirms, gc, entry);
                 bzero(gc, sizeof(*gc));                  bzero(gc, sizeof(*gc));
                 xfree(gc);                  free(gc);
         }          }
   
         packet_set_alive_timeouts(0);          packet_set_alive_timeouts(0);
Line 817 
Line 815 
                         chan_write_failed(c);                          chan_write_failed(c);
                 }                  }
         }          }
         xfree(cr);          free(cr);
 }  }
   
 static void  static void
 client_abandon_status_confirm(Channel *c, void *ctx)  client_abandon_status_confirm(Channel *c, void *ctx)
 {  {
         xfree(ctx);          free(ctx);
 }  }
   
 void  void
Line 990 
Line 988 
 out:  out:
         signal(SIGINT, handler);          signal(SIGINT, handler);
         enter_raw_mode(options.request_tty == REQUEST_TTY_FORCE);          enter_raw_mode(options.request_tty == REQUEST_TTY_FORCE);
         if (cmd)          free(cmd);
                 xfree(cmd);          free(fwd.listen_host);
         if (fwd.listen_host != NULL)          free(fwd.connect_host);
                 xfree(fwd.listen_host);  
         if (fwd.connect_host != NULL)  
                 xfree(fwd.connect_host);  
 }  }
   
 /* reasons to suppress output of an escape command in help output */  /* reasons to suppress output of an escape command in help output */
Line 1252 
Line 1247 
                                 buffer_append(berr, string, strlen(string));                                  buffer_append(berr, string, strlen(string));
                                 s = channel_open_message();                                  s = channel_open_message();
                                 buffer_append(berr, s, strlen(s));                                  buffer_append(berr, s, strlen(s));
                                 xfree(s);                                  free(s);
                                 continue;                                  continue;
   
                         case 'C':                          case 'C':
Line 1438 
Line 1433 
 void  void
 client_filter_cleanup(int cid, void *ctx)  client_filter_cleanup(int cid, void *ctx)
 {  {
         xfree(ctx);          free(ctx);
 }  }
   
 int  int
Line 1649 
Line 1644 
                         }                          }
                 }                  }
         }          }
         if (readset)          free(readset);
                 xfree(readset);          free(writeset);
         if (writeset)  
                 xfree(writeset);  
   
         /* Terminate the session. */          /* Terminate the session. */
   
Line 1754 
Line 1747 
         packet_check_eom();          packet_check_eom();
         buffer_append(&stdout_buffer, data, data_len);          buffer_append(&stdout_buffer, data, data_len);
         memset(data, 0, data_len);          memset(data, 0, data_len);
         xfree(data);          free(data);
 }  }
 static void  static void
 client_input_stderr_data(int type, u_int32_t seq, void *ctxt)  client_input_stderr_data(int type, u_int32_t seq, void *ctxt)
Line 1764 
Line 1757 
         packet_check_eom();          packet_check_eom();
         buffer_append(&stderr_buffer, data, data_len);          buffer_append(&stderr_buffer, data, data_len);
         memset(data, 0, data_len);          memset(data, 0, data_len);
         xfree(data);          free(data);
 }  }
 static void  static void
 client_input_exit_status(int type, u_int32_t seq, void *ctxt)  client_input_exit_status(int type, u_int32_t seq, void *ctxt)
Line 1844 
Line 1837 
         c = channel_connect_by_listen_address(listen_port,          c = channel_connect_by_listen_address(listen_port,
             "forwarded-tcpip", originator_address);              "forwarded-tcpip", originator_address);
   
         xfree(originator_address);          free(originator_address);
         xfree(listen_address);          free(listen_address);
         return c;          return c;
 }  }
   
Line 1879 
Line 1872 
         /* XXX check permission */          /* XXX check permission */
         debug("client_request_x11: request from %s %d", originator,          debug("client_request_x11: request from %s %d", originator,
             originator_port);              originator_port);
         xfree(originator);          free(originator);
         sock = x11_connect_display();          sock = x11_connect_display();
         if (sock < 0)          if (sock < 0)
                 return NULL;                  return NULL;
Line 2000 
Line 1993 
                 }                  }
                 packet_send();                  packet_send();
         }          }
         xfree(ctype);          free(ctype);
 }  }
 static void  static void
 client_input_channel_req(int type, u_int32_t seq, void *ctxt)  client_input_channel_req(int type, u_int32_t seq, void *ctxt)
Line 2046 
Line 2039 
                 packet_put_int(c->remote_id);                  packet_put_int(c->remote_id);
                 packet_send();                  packet_send();
         }          }
         xfree(rtype);          free(rtype);
 }  }
 static void  static void
 client_input_global_request(int type, u_int32_t seq, void *ctxt)  client_input_global_request(int type, u_int32_t seq, void *ctxt)
Line 2065 
Line 2058 
                 packet_send();                  packet_send();
                 packet_write_wait();                  packet_write_wait();
         }          }
         xfree(rtype);          free(rtype);
 }  }
   
 void  void
Line 2115 
Line 2108 
                         /* Split */                          /* Split */
                         name = xstrdup(env[i]);                          name = xstrdup(env[i]);
                         if ((val = strchr(name, '=')) == NULL) {                          if ((val = strchr(name, '=')) == NULL) {
                                 xfree(name);                                  free(name);
                                 continue;                                  continue;
                         }                          }
                         *val++ = '\0';                          *val++ = '\0';
Line 2129 
Line 2122 
                         }                          }
                         if (!matched) {                          if (!matched) {
                                 debug3("Ignored env %s", name);                                  debug3("Ignored env %s", name);
                                 xfree(name);                                  free(name);
                                 continue;                                  continue;
                         }                          }
   
Line 2138 
Line 2131 
                         packet_put_cstring(name);                          packet_put_cstring(name);
                         packet_put_cstring(val);                          packet_put_cstring(val);
                         packet_send();                          packet_send();
                         xfree(name);                          free(name);
                 }                  }
         }          }
   

Legend:
Removed from v.1.249  
changed lines
  Added in v.1.250