version 1.153, 2014/06/21 16:18:25 |
version 1.159, 2014/08/23 18:13:47 |
|
|
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF |
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF |
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. |
*/ |
*/ |
#ifdef HAVE_CONFIG_H |
|
#include "config.h" |
#include "config.h" |
#endif |
|
|
|
#include <sys/stat.h> |
#include <sys/stat.h> |
|
#include <sys/types.h> |
#include <sys/wait.h> |
#include <sys/wait.h> |
|
|
#include <assert.h> |
#include <assert.h> |
#include <ctype.h> |
#include <ctype.h> |
#include <errno.h> |
#include <errno.h> |
#include <fcntl.h> |
#include <fcntl.h> |
|
#if HAVE_FTS |
#include <fts.h> |
#include <fts.h> |
|
#else |
|
#include "compat_fts.h" |
|
#endif |
#include <getopt.h> |
#include <getopt.h> |
#include <limits.h> |
#include <limits.h> |
#include <stddef.h> |
#include <stddef.h> |
|
|
#include <string.h> |
#include <string.h> |
#include <unistd.h> |
#include <unistd.h> |
|
|
#ifdef HAVE_OHASH |
#if HAVE_OHASH |
#include <ohash.h> |
#include <ohash.h> |
#else |
#else |
#include "compat_ohash.h" |
#include "compat_ohash.h" |
Line 1198 mpages_merge(struct mchars *mc, struct mparse *mp) |
|
Line 1201 mpages_merge(struct mchars *mc, struct mparse *mp) |
|
goto nextpage; |
goto nextpage; |
} else if (NULL != mdoc) { |
} else if (NULL != mdoc) { |
mpage->form = FORM_SRC; |
mpage->form = FORM_SRC; |
mpage->sec = |
mpage->sec = mdoc_meta(mdoc)->msec; |
mandoc_strdup(mdoc_meta(mdoc)->msec); |
mpage->sec = mandoc_strdup( |
|
NULL == mpage->sec ? "" : mpage->sec); |
mpage->arch = mdoc_meta(mdoc)->arch; |
mpage->arch = mdoc_meta(mdoc)->arch; |
mpage->arch = mandoc_strdup( |
mpage->arch = mandoc_strdup( |
NULL == mpage->arch ? "" : mpage->arch); |
NULL == mpage->arch ? "" : mpage->arch); |
Line 1306 names_check(void) |
|
Line 1310 names_check(void) |
|
say("", "%s", sqlite3_errmsg(db)); |
say("", "%s", sqlite3_errmsg(db)); |
|
|
while (SQLITE_ROW == (irc = sqlite3_step(stmt))) { |
while (SQLITE_ROW == (irc = sqlite3_step(stmt))) { |
name = sqlite3_column_text(stmt, 0); |
name = (const char *)sqlite3_column_text(stmt, 0); |
sec = sqlite3_column_text(stmt, 1); |
sec = (const char *)sqlite3_column_text(stmt, 1); |
arch = sqlite3_column_text(stmt, 2); |
arch = (const char *)sqlite3_column_text(stmt, 2); |
key = sqlite3_column_text(stmt, 3); |
key = (const char *)sqlite3_column_text(stmt, 3); |
say("", "%s(%s%s%s) lacks mlink \"%s\"", name, sec, |
say("", "%s(%s%s%s) lacks mlink \"%s\"", name, sec, |
'\0' == *arch ? "" : "/", |
'\0' == *arch ? "" : "/", |
'\0' == *arch ? "" : arch, key); |
'\0' == *arch ? "" : arch, key); |
Line 1328 parse_cat(struct mpage *mpage, int fd) |
|
Line 1332 parse_cat(struct mpage *mpage, int fd) |
|
fopen(mpage->mlinks->file, "r") : |
fopen(mpage->mlinks->file, "r") : |
fdopen(fd, "r"); |
fdopen(fd, "r"); |
if (NULL == stream) { |
if (NULL == stream) { |
|
if (-1 != fd) |
|
close(fd); |
if (warnings) |
if (warnings) |
say(mpage->mlinks->file, "&fopen"); |
say(mpage->mlinks->file, "&fopen"); |
return; |
return; |