summaryrefslogtreecommitdiff
path: root/usr.sbin/dhcpd/tree.c
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2004-04-16 04:30:10 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2004-04-16 04:30:10 +0000
commit27838d159af1013338d85a71c521ecc43a8d0e68 (patch)
tree35d4d04bf5683cec8f43ed8867f90ef48a64c961 /usr.sbin/dhcpd/tree.c
parentbb823301160915b076bd09ee468d5e675c858a45 (diff)
a bunch of knf, ok henning
Diffstat (limited to 'usr.sbin/dhcpd/tree.c')
-rw-r--r--usr.sbin/dhcpd/tree.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/dhcpd/tree.c b/usr.sbin/dhcpd/tree.c
index d19b7981fe3..fe8bce94c86 100644
--- a/usr.sbin/dhcpd/tree.c
+++ b/usr.sbin/dhcpd/tree.c
@@ -1,4 +1,4 @@
-/* $Id: tree.c,v 1.5 2004/04/15 21:47:13 hshoexer Exp $ */
+/* $Id: tree.c,v 1.6 2004/04/16 04:30:09 deraadt Exp $ */
/* Routines for manipulating parse trees... */
@@ -53,7 +53,7 @@ cons(caddr_t car, pair cdr)
{
pair foo = (pair)dmalloc(sizeof *foo, "cons");
if (!foo)
- error ("no memory for cons.");
+ error("no memory for cons.");
foo->car = car;
foo->cdr = cdr;
return foo;
@@ -138,6 +138,7 @@ tree_concat(struct tree *left, struct tree *right)
if (left->op == TREE_CONST && right->op == TREE_CONST) {
unsigned char *buf = dmalloc(left->data.const_val.len
+ right->data.const_val.len, "tree_concat");
+
if (!buf)
error("No memory to concatenate constants.");
memcpy(buf, left->data.const_val.data,