summaryrefslogtreecommitdiffstats
path: root/man.c
diff options
context:
space:
mode:
Diffstat (limited to 'man.c')
-rw-r--r--man.c9
1 files changed, 1 insertions, 8 deletions
diff --git a/man.c b/man.c
index 3bfbb4a4..b13039e8 100644
--- a/man.c
+++ b/man.c
@@ -320,16 +320,9 @@ int
man_word_alloc(struct man *m, int line, int pos, const char *word)
{
struct man_node *n;
- size_t sv, len;
-
- len = strlen(word);
n = man_node_alloc(m, line, pos, MAN_TEXT, MAN_MAX);
- n->string = mandoc_malloc(len + 1);
- sv = strlcpy(n->string, word, len + 1);
-
- /* Prohibit truncation. */
- assert(sv < len + 1);
+ n->string = mandoc_strdup(word);
if ( ! man_node_append(m, n))
return(0);