version 1.81, 2019/04/30 18:51:57 |
version 1.84, 2023/04/28 19:11:03 |
|
|
/* $Id$ */ |
/* $Id$ */ |
/* |
/* |
* Copyright (c) 2012 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2012 Kristaps Dzonsons <kristaps@bsd.lv> |
* Copyright (c) 2013-2018 Ingo Schwarze <schwarze@openbsd.org> |
* Copyright (c) 2013-2018 Ingo Schwarze <schwarze@openbsd.org> |
Line 191 mansearch(const struct mansearch *search, |
|
Line 191 mansearch(const struct mansearch *search, |
|
mpage->file, R_OK) == -1) { |
mpage->file, R_OK) == -1) { |
warn("%s", mpage->file); |
warn("%s", mpage->file); |
warnx("outdated mandoc.db contains " |
warnx("outdated mandoc.db contains " |
"bogus %s entry, run makewhatis %s", |
"bogus %s entry, run makewhatis %s", |
page->file + 1, paths->paths[i]); |
page->file + 1, paths->paths[i]); |
free(mpage->file); |
free(mpage->file); |
free(rp); |
free(rp); |
Line 220 mansearch(const struct mansearch *search, |
|
Line 220 mansearch(const struct mansearch *search, |
|
if (cur && search->firstmatch) |
if (cur && search->firstmatch) |
break; |
break; |
} |
} |
if (res != NULL) |
if (res != NULL && cur > 1) |
qsort(*res, cur, sizeof(struct manpage), manpage_compare); |
qsort(*res, cur, sizeof(struct manpage), manpage_compare); |
if (chdir_status && getcwd_status && chdir(buf) == -1) |
if (chdir_status && getcwd_status && chdir(buf) == -1) |
warn("%s", buf); |
warn("%s", buf); |
Line 491 lstlen(const char *cp, size_t sep) |
|
Line 491 lstlen(const char *cp, size_t sep) |
|
|
|
/* |
/* |
* Print the NUL-terminated list of NUL-terminated strings |
* Print the NUL-terminated list of NUL-terminated strings |
* into the buffer, seperating strings with sep. |
* into the buffer, separating strings with sep. |
*/ |
*/ |
static void |
static void |
lstcat(char *buf, size_t *i, const char *cp, const char *sep) |
lstcat(char *buf, size_t *i, const char *cp, const char *sep) |