From 5c3685fbee3bd6edd7c175ddde143036dd846c3f Mon Sep 17 00:00:00 2001 From: Theo de Raadt Date: Wed, 12 Jan 2000 00:42:47 +0000 Subject: indent the source right --- lib/libc/stdio/printf.3 | 23 ++++++++++++----------- 1 file changed, 12 insertions(+), 11 deletions(-) diff --git a/lib/libc/stdio/printf.3 b/lib/libc/stdio/printf.3 index aabe4fdb8bc..a214650bd09 100644 --- a/lib/libc/stdio/printf.3 +++ b/lib/libc/stdio/printf.3 @@ -1,4 +1,4 @@ -.\" $OpenBSD: printf.3,v 1.21 1999/09/22 10:05:25 espie Exp $ +.\" $OpenBSD: printf.3,v 1.22 2000/01/12 00:42:46 deraadt Exp $ .\" .\" Copyright (c) 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -574,7 +574,7 @@ are pointers to strings: #include fprintf(stdout, "%s, %s %d, %.2d:%.2d\en", - weekday, month, day, hour, min); + weekday, month, day, hour, min); .Ed .Pp To print \*(Pi @@ -592,17 +592,18 @@ To allocate a 128 byte string and print into it: #include #include -char *newfmt(const char *fmt, ...) +char * +newfmt(const char *fmt, ...) { - char *p; - va_list ap; + char *p; + va_list ap; - if ((p = malloc(128)) == NULL) - return (NULL); - va_start(ap, fmt); - (void) vsnprintf(p, 128, fmt, ap); - va_end(ap); - return (p); + if ((p = malloc(128)) == NULL) + return (NULL); + va_start(ap, fmt); + (void) vsnprintf(p, 128, fmt, ap); + va_end(ap); + return (p); } .Ed .Sh SEE ALSO -- cgit v1.2.3