diff options
author | Jason Wright <jason@cvs.openbsd.org> | 2002-01-03 19:28:38 +0000 |
---|---|---|
committer | Jason Wright <jason@cvs.openbsd.org> | 2002-01-03 19:28:38 +0000 |
commit | e8b0d0114c17881aded1035d7dd8137501bacb70 (patch) | |
tree | 1cfc45aeb615bd9ff1c0aec885489212c7450f2e /sys | |
parent | 4602cd6dc82fc66a9f169a963671a3599a004ac4 (diff) |
Proper va_end calling (no double calls)
Diffstat (limited to 'sys')
-rw-r--r-- | sys/arch/macppc/macppc/opendev.c | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/sys/arch/macppc/macppc/opendev.c b/sys/arch/macppc/macppc/opendev.c index 431d82ed98b..95d7f83fddb 100644 --- a/sys/arch/macppc/macppc/opendev.c +++ b/sys/arch/macppc/macppc/opendev.c @@ -1,4 +1,4 @@ -/* $OpenBSD: opendev.c,v 1.2 2001/09/05 22:32:38 deraadt Exp $ */ +/* $OpenBSD: opendev.c,v 1.3 2002/01/03 19:28:37 jason Exp $ */ /* $NetBSD: openfirm.c,v 1.1 1996/09/30 16:34:52 ws Exp $ */ /* @@ -185,14 +185,10 @@ OF_call_method_1(method, ihandle, nargs, va_alist) *--ip = va_arg(ap, int); va_end(ap); ofw_stack(); - if (openfirmware(&args) == -1) { - va_end(ap); + if (openfirmware(&args) == -1) return -1; - } - if (args.args_n_results[nargs]) { - va_end(ap); + if (args.args_n_results[nargs]) return -1; - } return args.args_n_results[nargs + 1]; } |