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

Diff for /src/usr.bin/ssh/sftp.c between version 1.205 and 1.206

version 1.205, 2020/12/04 02:41:10 version 1.206, 2021/01/08 02:44:14
Line 867 
Line 867 
 #define NCMP(a,b) (a == b ? 0 : (a < b ? 1 : -1))  #define NCMP(a,b) (a == b ? 0 : (a < b ? 1 : -1))
         if (sort_flag & LS_NAME_SORT)          if (sort_flag & LS_NAME_SORT)
                 return (rmul * strcmp(ap, bp));                  return (rmul * strcmp(ap, bp));
         else if (sort_flag & LS_TIME_SORT)          else if (sort_flag & LS_TIME_SORT) {
                 return (rmul * timespeccmp(&as->st_mtim, &bs->st_mtim, <));                  if (timespeccmp(&as->st_mtim, &bs->st_mtim, ==))
         else if (sort_flag & LS_SIZE_SORT)                          return 0;
                   return timespeccmp(&as->st_mtim, &bs->st_mtim, <) ?
                       rmul : -rmul;
           } else if (sort_flag & LS_SIZE_SORT)
                 return (rmul * NCMP(as->st_size, bs->st_size));                  return (rmul * NCMP(as->st_size, bs->st_size));
   
         fatal("Unknown ls sort type");          fatal("Unknown ls sort type");

Legend:
Removed from v.1.205  
changed lines
  Added in v.1.206