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

Diff for /src/usr.bin/newsyslog/newsyslog.c between version 1.44 and 1.45

version 1.44, 2002/06/12 06:07:16 version 1.45, 2002/06/26 23:36:14
Line 132 
Line 132 
 #define CE_BINARY       0x04            /* Logfile is in binary, don't add */  #define CE_BINARY       0x04            /* Logfile is in binary, don't add */
                                         /* status messages */                                          /* status messages */
 #define CE_MONITOR      0x08            /* Monitory for changes */  #define CE_MONITOR      0x08            /* Monitory for changes */
   #define CE_FOLLOW       0x10            /* Follow symbolic links */
 #define NONE -1  #define NONE -1
   
 struct conf_entry {  struct conf_entry {
Line 267 
Line 268 
   
 {  {
         int     modtime, size;          int     modtime, size;
           struct  stat sta;
   
           if (!(ent->flags & CE_FOLLOW)) {
                   if (lstat(ent->log, &sta) != 0)
                           return;
                   if ((sta.st_mode & S_IFLNK) != S_IFREG) {
                           if (verbose) {
                                   printf("--> %s is not a regular file, skip\n",
                                       ent->log);
                                   return;
                           }
                   }
           }
   
         if (verbose)          if (verbose)
                 printf("%s <%d%s>: ", ent->log, ent->numlogs,                  printf("%s <%d%s>: ", ent->log, ent->numlogs,
                         (ent->flags & CE_COMPACT) ? "Z" : "");                          (ent->flags & CE_COMPACT) ? "Z" : "");
Line 532 
Line 546 
                                 case 'M':                                  case 'M':
                                 case 'm':                                  case 'm':
                                         working->flags |= CE_MONITOR;                                          working->flags |= CE_MONITOR;
                                           break;
                                   case 'F':
                                   case 'f':
                                           working->flags |= CE_FOLLOW;
                                         break;                                          break;
                                 default:                                  default:
                                         errx(1, "Illegal flag in config file: %c", *q);                                          errx(1, "Illegal flag in config file: %c", *q);

Legend:
Removed from v.1.44  
changed lines
  Added in v.1.45