[BACK]Return to mandocdb.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/mandocdb.c between version 1.206 and 1.207

version 1.206, 2015/11/06 16:30:33 version 1.207, 2015/11/06 17:33:34
Line 337  mandocdb(int argc, char *argv[])
Line 337  mandocdb(int argc, char *argv[])
         size_t            j, sz;          size_t            j, sz;
         int               ch, i;          int               ch, i;
   
   #if HAVE_PLEDGE
           if (pledge("stdio rpath wpath cpath fattr flock proc exec", NULL) == -1) {
                   perror("pledge");
                   return (int)MANDOCLEVEL_SYSERR;
           }
   #endif
   
         memset(&conf, 0, sizeof(conf));          memset(&conf, 0, sizeof(conf));
         memset(stmts, 0, STMT__MAX * sizeof(sqlite3_stmt *));          memset(stmts, 0, STMT__MAX * sizeof(sqlite3_stmt *));
   
Line 410  mandocdb(int argc, char *argv[])
Line 417  mandocdb(int argc, char *argv[])
         argc -= optind;          argc -= optind;
         argv += optind;          argv += optind;
   
   #if HAVE_PLEDGE
           if (nodb && pledge("stdio rpath", NULL) == -1) {
                   perror("pledge");
                   return (int)MANDOCLEVEL_SYSERR;
           }
   #endif
   
         if (OP_CONFFILE == op && argc > 0) {          if (OP_CONFFILE == op && argc > 0) {
                 warnx("-C: Too many arguments");                  warnx("-C: Too many arguments");
                 goto usage;                  goto usage;
Line 435  mandocdb(int argc, char *argv[])
Line 449  mandocdb(int argc, char *argv[])
                          * The existing database is usable.  Process                           * The existing database is usable.  Process
                          * all files specified on the command-line.                           * all files specified on the command-line.
                          */                           */
   #if HAVE_PLEDGE
                           if (!nodb && pledge("stdio rpath wpath cpath fattr flock",
                               NULL) == -1) {
                                   perror("pledge");
                                   exitcode = (int)MANDOCLEVEL_SYSERR;
                                   goto out;
                           }
   #endif
                         use_all = 1;                          use_all = 1;
                         for (i = 0; i < argc; i++)                          for (i = 0; i < argc; i++)
                                 filescan(argv[i]);                                  filescan(argv[i]);

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

CVSweb