summaryrefslogtreecommitdiff
path: root/usr.bin/cvs/rcsnum.c
diff options
context:
space:
mode:
authorXavier Santolaria <xsa@cvs.openbsd.org>2006-04-06 12:12:08 +0000
committerXavier Santolaria <xsa@cvs.openbsd.org>2006-04-06 12:12:08 +0000
commit7839c9030755cddf1dcf24b22b2a665b5e441095 (patch)
treee739da190c8ec558401c74ca95737f6ce89e2830 /usr.bin/cvs/rcsnum.c
parentf147c46c3ca2c595bdea9002e527d32344e199c3 (diff)
rcsnum_setsize() will never return non-zero; change its return type to void.
Diffstat (limited to 'usr.bin/cvs/rcsnum.c')
-rw-r--r--usr.bin/cvs/rcsnum.c13
1 files changed, 4 insertions, 9 deletions
diff --git a/usr.bin/cvs/rcsnum.c b/usr.bin/cvs/rcsnum.c
index 8a6a6a6538e..44ec6a8c7b3 100644
--- a/usr.bin/cvs/rcsnum.c
+++ b/usr.bin/cvs/rcsnum.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rcsnum.c,v 1.32 2006/04/05 01:38:56 ray Exp $ */
+/* $OpenBSD: rcsnum.c,v 1.33 2006/04/06 12:12:07 xsa Exp $ */
/*
* Copyright (c) 2004 Jean-Francois Brousseau <jfb@openbsd.org>
* All rights reserved.
@@ -31,7 +31,7 @@
#include "rcs.h"
-static int rcsnum_setsize(RCSNUM *, u_int);
+static void rcsnum_setsize(RCSNUM *, u_int);
static char *rcsnum_itoa(u_int16_t, char *, size_t);
@@ -385,18 +385,14 @@ rcsnum_brtorev(const RCSNUM *brnum)
}
num = rcsnum_alloc();
- if (rcsnum_setsize(num, brnum->rn_len + 1) < 0) {
- rcsnum_free(num);
- return (NULL);
- }
-
+ rcsnum_setsize(num, brnum->rn_len + 1);
rcsnum_cpy(brnum, num, brnum->rn_len);
num->rn_id[num->rn_len++] = 1;
return (num);
}
-static int
+static void
rcsnum_setsize(RCSNUM *num, u_int len)
{
void *tmp;
@@ -404,5 +400,4 @@ rcsnum_setsize(RCSNUM *num, u_int len)
tmp = xrealloc(num->rn_id, len, sizeof(*(num->rn_id)));
num->rn_id = tmp;
num->rn_len = len;
- return (0);
}