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

Diff for /src/usr.bin/ssh/ssh-keyscan.c between version 1.47 and 1.47.2.1

version 1.47, 2004/03/08 09:38:05 version 1.47.2.1, 2004/08/19 04:13:27
Line 336 
Line 336 
             "ssh-dss": "ssh-rsa";              "ssh-dss": "ssh-rsa";
         c->c_kex = kex_setup(myproposal);          c->c_kex = kex_setup(myproposal);
         c->c_kex->kex[KEX_DH_GRP1_SHA1] = kexdh_client;          c->c_kex->kex[KEX_DH_GRP1_SHA1] = kexdh_client;
           c->c_kex->kex[KEX_DH_GRP14_SHA1] = kexdh_client;
         c->c_kex->kex[KEX_DH_GEX_SHA1] = kexgex_client;          c->c_kex->kex[KEX_DH_GEX_SHA1] = kexgex_client;
         c->c_kex->verify_host_key = hostjump;          c->c_kex->verify_host_key = hostjump;
   
Line 383 
Line 384 
                         error("socket: %s", strerror(errno));                          error("socket: %s", strerror(errno));
                         continue;                          continue;
                 }                  }
                 if (fcntl(s, F_SETFL, O_NONBLOCK) < 0)                  if (set_nonblock(s) == -1)
                         fatal("F_SETFL: %s", strerror(errno));                          fatal("%s: set_nonblock(%d)", __func__, s);
                 if (connect(s, ai->ai_addr, ai->ai_addrlen) < 0 &&                  if (connect(s, ai->ai_addr, ai->ai_addrlen) < 0 &&
                     errno != EINPROGRESS)                      errno != EINPROGRESS)
                         error("connect (`%s'): %s", host, strerror(errno));                          error("connect (`%s'): %s", host, strerror(errno));
Line 484 
Line 485 
   
         bufsiz = sizeof(buf);          bufsiz = sizeof(buf);
         cp = buf;          cp = buf;
         while (bufsiz-- && (n = read(s, cp, 1)) == 1 && *cp != '\n') {          while (bufsiz-- && (n = atomicio(read, s, cp, 1)) == 1 && *cp != '\n') {
                 if (*cp == '\r')                  if (*cp == '\r')
                         *cp = '\n';                          *cp = '\n';
                 cp++;                  cp++;
Line 550 
Line 551 
                 congreet(s);                  congreet(s);
                 return;                  return;
         }          }
         n = read(s, c->c_data + c->c_off, c->c_len - c->c_off);          n = atomicio(read, s, c->c_data + c->c_off, c->c_len - c->c_off);
         if (n < 0) {          if (n < 0) {
                 error("read (%s): %s", c->c_name, strerror(errno));                  error("read (%s): %s", c->c_name, strerror(errno));
                 confree(s);                  confree(s);

Legend:
Removed from v.1.47  
changed lines
  Added in v.1.47.2.1