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

Diff for /src/usr.bin/sort/sort.c between version 1.75 and 1.76

version 1.75, 2015/04/03 10:07:25 version 1.76, 2015/04/03 10:37:24
Line 857 
Line 857 
 main(int argc, char *argv[])  main(int argc, char *argv[])
 {  {
         char *outfile, *real_outfile, *sflag;          char *outfile, *real_outfile, *sflag;
         int c, result;          int c;
         size_t i;          size_t i;
         bool mef_flags[NUMBER_OF_MUTUALLY_EXCLUSIVE_FLAGS] =          bool mef_flags[NUMBER_OF_MUTUALLY_EXCLUSIVE_FLAGS] =
             { false, false, false, false, false, false };              { false, false, false, false, false, false };
   
         result = 0;  
         outfile = "-";          outfile = "-";
         real_outfile = NULL;          real_outfile = NULL;
         sflag = NULL;          sflag = NULL;
Line 1094 
Line 1093 
                 }                  }
         }          }
   
           if (sort_opts_vals.cflag)
                   return check(argc ? *argv : "-");
   
         set_random_seed();          set_random_seed();
   
         /* Case when the outfile equals one of the input files: */          /* Case when the outfile equals one of the input files: */
Line 1120 
Line 1122 
                 }                  }
         }          }
   
         if (!sort_opts_vals.cflag && !sort_opts_vals.mflag) {          if (!sort_opts_vals.mflag) {
                 struct file_list fl;                  struct file_list fl;
                 struct sort_list list;                  struct sort_list list;
   
Line 1158 
Line 1160 
                  * sort_list_clean(&list);                   * sort_list_clean(&list);
                  */                   */
   
         } else if (sort_opts_vals.cflag) {          } else {
                 result = (argc == 0) ? (check("-")) : (check(*argv));  
         } else if (sort_opts_vals.mflag) {  
                 struct file_list fl;                  struct file_list fl;
   
                 file_list_init(&fl, false);                  file_list_init(&fl, false);
Line 1175 
Line 1175 
                 sort_free(outfile);                  sort_free(outfile);
         }          }
   
         return result;          return 0;
 }  }

Legend:
Removed from v.1.75  
changed lines
  Added in v.1.76