diff options
| author | Charles.Forsyth <devnull@localhost> | 2007-06-08 10:51:11 +0000 |
|---|---|---|
| committer | Charles.Forsyth <devnull@localhost> | 2007-06-08 10:51:11 +0000 |
| commit | 1f44c82a26ff60e012a2ff697cb036a25c0c7f97 (patch) | |
| tree | 73cb74c31ef90c5ee906bbdf9040f8e9d8ebbb20 /lib9/fmtprint.c | |
| parent | 7d5a2526f46cd3474fb96a684f7b87e9e78128b0 (diff) | |
20070608-1149
Diffstat (limited to 'lib9/fmtprint.c')
| -rw-r--r-- | lib9/fmtprint.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib9/fmtprint.c b/lib9/fmtprint.c index c93cb315..549049a3 100644 --- a/lib9/fmtprint.c +++ b/lib9/fmtprint.c @@ -29,14 +29,16 @@ fmtprint(Fmt *f, char *fmt, ...) f->flags = 0; f->width = 0; f->prec = 0; - va = f->args; + va_copy(va, f->args); + va_end(f->args); va_start(f->args, fmt); n = dofmt(f, fmt); va_end(f->args); f->flags = 0; f->width = 0; f->prec = 0; - f->args = va; + va_copy(f->args, va); + va_end(va); if(n >= 0) return 0; return n; |
