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

Diff for /src/usr.bin/rdist/docmd.c between version 1.33 and 1.34

version 1.33, 2017/07/09 14:04:50 version 1.34, 2019/06/28 13:35:03
Line 115 
Line 115 
   
         debugmsg(DM_MISC, "notify() temp file = '%s'", file);          debugmsg(DM_MISC, "notify() temp file = '%s'", file);
   
         if ((fd = open(file, O_RDONLY)) < 0) {          if ((fd = open(file, O_RDONLY)) == -1) {
                 error("%s: open for reading failed: %s", file, SYSERR);                  error("%s: open for reading failed: %s", file, SYSERR);
                 return;                  return;
         }          }
         if (fstat(fd, &stb) < 0) {          if (fstat(fd, &stb) == -1) {
                 error("%s: fstat failed: %s", file, SYSERR);                  error("%s: fstat failed: %s", file, SYSERR);
                 (void) close(fd);                  (void) close(fd);
                 return;                  return;
Line 671 
Line 671 
                 while (*ptarget)                  while (*ptarget)
                         ptarget++;                          ptarget++;
         }          }
         if (access(name, R_OK) < 0 || stat(name, &stb) < 0) {          if (access(name, R_OK) == -1 || stat(name, &stb) == -1) {
                 error("%s: cannot access file: %s", name, SYSERR);                  error("%s: cannot access file: %s", name, SYSERR);
                 return;                  return;
         }          }
Line 730 
Line 730 
                       cmd->c_label);                        cmd->c_label);
                 return;                  return;
         }          }
         if (stat(stamp, &stb) < 0) {          if (stat(stamp, &stb) == -1) {
                 error("%s: stat failed: %s", stamp, SYSERR);                  error("%s: stat failed: %s", stamp, SYSERR);
                 return;                  return;
         }          }

Legend:
Removed from v.1.33  
changed lines
  Added in v.1.34