version 1.32.2.4, 2014/01/22 21:02:54 |
version 1.32.2.6, 2014/04/23 21:31:38 |
|
|
#include "mandocdb.h" |
#include "mandocdb.h" |
#include "apropos_db.h" |
#include "apropos_db.h" |
#include "mandoc.h" |
#include "mandoc.h" |
|
#include "mandoc_aux.h" |
|
|
#define RESFREE(_x) \ |
#define RESFREE(_x) \ |
do { \ |
do { \ |
Line 554 single_search(struct rectree *tree, const struct opts |
|
Line 555 single_search(struct rectree *tree, const struct opts |
|
if (strcasecmp(opts->arch, r.arch)) |
if (strcasecmp(opts->arch, r.arch)) |
continue; |
continue; |
|
|
tree->node = rs = mandoc_realloc |
tree->node = rs = mandoc_reallocarray(rs, |
(rs, (tree->len + 1) * sizeof(struct res)); |
tree->len + 1, sizeof(struct res)); |
|
|
memcpy(&rs[tree->len], &r, sizeof(struct res)); |
memcpy(&rs[tree->len], &r, sizeof(struct res)); |
memset(&r, 0, sizeof(struct res)); |
memset(&r, 0, sizeof(struct res)); |