diff options
author | marius <marius@FreeBSD.org> | 2009-03-29 15:10:49 +0000 |
---|---|---|
committer | marius <marius@FreeBSD.org> | 2009-03-29 15:10:49 +0000 |
commit | aa09259c5bcc6d45a8e5cab2cb09d667d8d3c78e (patch) | |
tree | b57c2dbd7aa1591f7c15515ad18785066221877c | |
parent | b6886fc07bf36dc70112c995c8aa3da4f60e3688 (diff) | |
download | FreeBSD-src-aa09259c5bcc6d45a8e5cab2cb09d667d8d3c78e.zip FreeBSD-src-aa09259c5bcc6d45a8e5cab2cb09d667d8d3c78e.tar.gz |
Unbreak OF_interpret() and its standard implementation after r186347.
-rw-r--r-- | sys/dev/ofw/ofw_standard.c | 2 | ||||
-rw-r--r-- | sys/dev/ofw/openfirm.c | 4 |
2 files changed, 4 insertions, 2 deletions
diff --git a/sys/dev/ofw/ofw_standard.c b/sys/dev/ofw/ofw_standard.c index e097145..a05f072 100644 --- a/sys/dev/ofw/ofw_standard.c +++ b/sys/dev/ofw/ofw_standard.c @@ -204,7 +204,7 @@ ofw_std_interpret(ofw_t ofw, const char *cmd, int nreturns, } status = args.slot[i++]; while (i < 1 + nreturns) - returns[j] = args.slot[i++]; + returns[j++] = args.slot[i++]; return (status); } diff --git a/sys/dev/ofw/openfirm.c b/sys/dev/ofw/openfirm.c index 4c33c9f..06b58d0 100644 --- a/sys/dev/ofw/openfirm.c +++ b/sys/dev/ofw/openfirm.c @@ -164,9 +164,11 @@ OF_interpret(const char *cmd, int nreturns, ...) int status; status = OFW_INTERPRET(ofw_obj, cmd, nreturns, slots); + if (status == -1) + return (status); va_start(ap, nreturns); - while (i < 1 + nreturns) + while (i < nreturns) *va_arg(ap, cell_t *) = slots[i++]; va_end(ap); |