Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/common/lib/libutil The PUT* things are macros. Use { ... } ...
details: https://anonhg.NetBSD.org/src/rev/8c66a91c4f77
branches: trunk
changeset: 789132:8c66a91c4f77
user: pgoyette <pgoyette%NetBSD.org@localhost>
date: Wed Aug 07 23:48:13 2013 +0000
description:
The PUT* things are macros. Use { ... } to make sure they expand correctly.
diffstat:
common/lib/libutil/snprintb.c | 12 +++++++-----
1 files changed, 7 insertions(+), 5 deletions(-)
diffs (42 lines):
diff -r cc91051bb333 -r 8c66a91c4f77 common/lib/libutil/snprintb.c
--- a/common/lib/libutil/snprintb.c Wed Aug 07 23:22:28 2013 +0000
+++ b/common/lib/libutil/snprintb.c Wed Aug 07 23:48:13 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: snprintb.c,v 1.10 2013/08/07 22:37:28 pgoyette Exp $ */
+/* $NetBSD: snprintb.c,v 1.11 2013/08/07 23:48:13 pgoyette Exp $ */
/*-
* Copyright (c) 2002 The NetBSD Foundation, Inc.
@@ -41,7 +41,7 @@
# include <sys/cdefs.h>
# if defined(LIBC_SCCS) && !defined(lint)
-__RCSID("$NetBSD: snprintb.c,v 1.10 2013/08/07 22:37:28 pgoyette Exp $");
+__RCSID("$NetBSD: snprintb.c,v 1.11 2013/08/07 23:48:13 pgoyette Exp $");
# endif
# include <sys/types.h>
@@ -51,7 +51,7 @@
# include <errno.h>
# else /* ! _KERNEL */
# include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: snprintb.c,v 1.10 2013/08/07 22:37:28 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: snprintb.c,v 1.11 2013/08/07 23:48:13 pgoyette Exp $");
# include <sys/param.h>
# include <sys/inttypes.h>
# include <sys/systm.h>
@@ -215,10 +215,12 @@
sep = ',';
if (ch == 'F') /* just extract */
break;
- if (restart == 0)
+ if (restart == 0) {
PUTS(bitfmt);
- if (restart == 0)
+ }
+ if (restart == 0) {
PUTCHR('=');
+ }
if (restart == 0) {
f_len = snprintf(bp, buflen - t_len,
sbase, field);
Home |
Main Index |
Thread Index |
Old Index