"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "mandocdb.c" between
mdocml-1.13.4rc1.tar.gz and mdocml-1.13.4rc2.tar.gz

About: mdocml is a suite of tools compiling "-mdoc", the roff macro package of choice for BSD manual pages, and "-man", the predominant historical package for UNIX manuals. Hint: The installed binary name is "mandoc". Release candidate.

mandocdb.c  (mdocml-1.13.4rc1):mandocdb.c  (mdocml-1.13.4rc2)
/* $Id: mandocdb.c,v 1.216 2016/03/17 21:26:26 schwarze Exp $ */ /* $Id: mandocdb.c,v 1.218 2016/07/12 05:18:38 kristaps Exp $ */
/* /*
* Copyright (c) 2011, 2012 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2011, 2012 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2011-2016 Ingo Schwarze <schwarze@openbsd.org> * Copyright (c) 2011-2016 Ingo Schwarze <schwarze@openbsd.org>
* *
* Permission to use, copy, modify, and distribute this software for any * Permission to use, copy, modify, and distribute this software for any
* purpose with or without fee is hereby granted, provided that the above * purpose with or without fee is hereby granted, provided that the above
* copyright notice and this permission notice appear in all copies. * copyright notice and this permission notice appear in all copies.
* *
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHORS DISCLAIM ALL WARRANTIES * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHORS DISCLAIM ALL WARRANTIES
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
skipping to change at line 36 skipping to change at line 36
#if HAVE_ERR #if HAVE_ERR
#include <err.h> #include <err.h>
#endif #endif
#include <errno.h> #include <errno.h>
#include <fcntl.h> #include <fcntl.h>
#if HAVE_FTS #if HAVE_FTS
#include <fts.h> #include <fts.h>
#else #else
#include "compat_fts.h" #include "compat_fts.h"
#endif #endif
#include <getopt.h>
#include <limits.h> #include <limits.h>
#if HAVE_SANDBOX_INIT
#include <sandbox.h>
#endif
#include <stddef.h> #include <stddef.h>
#include <stdio.h> #include <stdio.h>
#include <stdint.h> #include <stdint.h>
#include <stdlib.h> #include <stdlib.h>
#include <string.h> #include <string.h>
#include <unistd.h> #include <unistd.h>
#include <sqlite3.h> #include <sqlite3.h>
#include "mandoc_aux.h" #include "mandoc_aux.h"
skipping to change at line 348 skipping to change at line 350
size_t j, sz; size_t j, sz;
int ch, i; int ch, i;
#if HAVE_PLEDGE #if HAVE_PLEDGE
if (pledge("stdio rpath wpath cpath fattr flock proc exec", NULL) == -1) { if (pledge("stdio rpath wpath cpath fattr flock proc exec", NULL) == -1) {
warn("pledge"); warn("pledge");
return (int)MANDOCLEVEL_SYSERR; return (int)MANDOCLEVEL_SYSERR;
} }
#endif #endif
#if HAVE_SANDBOX_INIT
if (sandbox_init(kSBXProfileNoInternet, SANDBOX_NAMED, NULL) == -1) {
warnx("sandbox_init");
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 *));
/* /*
* We accept a few different invocations. * We accept a few different invocations.
* The CHECKOP macro makes sure that invocation styles don't * The CHECKOP macro makes sure that invocation styles don't
* clobber each other. * clobber each other.
*/ */
#define CHECKOP(_op, _ch) do \ #define CHECKOP(_op, _ch) do \
if (OP_DEFAULT != (_op)) { \ if (OP_DEFAULT != (_op)) { \
 End of changes. 4 change blocks. 
2 lines changed or deleted 11 lines changed or added

Home  |  About  |  All  |  Newest  |  Fossies Dox  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTPS