diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2009-01-16 15:58:50 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2009-01-16 15:58:50 +0000 |
commit | 50c7e68a675c2b7d573e94e93564b37785d2cad6 (patch) | |
tree | 11e1cf0f02ae887d2f5cafa23e29d58e04a3d5d9 /mdoc.c | |
parent | 74e24071f684da83ad181e5fec715d15f5f4dfae (diff) | |
download | mandoc-50c7e68a675c2b7d573e94e93564b37785d2cad6.tar.gz |
Initial separation of tree/mdocml.1.
Finished mdoc.3.
Broken build: mdocml.c.
Diffstat (limited to 'mdoc.c')
-rw-r--r-- | mdoc.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -241,7 +241,8 @@ mdoc_alloc(void *data, const struct mdoc_cb *cb) p = xcalloc(1, sizeof(struct mdoc)); p->data = data; - (void)memcpy(&p->cb, cb, sizeof(struct mdoc_cb)); + if (cb) + (void)memcpy(&p->cb, cb, sizeof(struct mdoc_cb)); p->last = xcalloc(1, sizeof(struct mdoc_node)); p->last->type = MDOC_ROOT; |