Module Name: src Committed By: uwe Date: Sun Jan 20 11:01:17 UTC 2013
Modified Files: src/lib/libc/stdio: printf.3 Log Message: Mark up occurence of printf() in text with .Fn To generate a diff of this commit: cvs rdiff -u -r1.60 -r1.61 src/lib/libc/stdio/printf.3 Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.
Modified files: Index: src/lib/libc/stdio/printf.3 diff -u src/lib/libc/stdio/printf.3:1.60 src/lib/libc/stdio/printf.3:1.61 --- src/lib/libc/stdio/printf.3:1.60 Sun Jan 20 10:57:19 2013 +++ src/lib/libc/stdio/printf.3 Sun Jan 20 11:01:17 2013 @@ -1,4 +1,4 @@ -.\" $NetBSD: printf.3,v 1.60 2013/01/20 10:57:19 uwe Exp $ +.\" $NetBSD: printf.3,v 1.61 2013/01/20 11:01:17 uwe Exp $ .\" .\" Copyright (c) 1990, 1991, 1993 .\" The Regents of the University of California. All rights reserved. @@ -884,7 +884,9 @@ Be sure to use the proper secure idiom: snprintf(buffer, sizeof(buffer), "%s", string); .Ed .Pp -There is no way for printf to know the size of each argument passed. +There is no way for +.Fn printf +to know the size of each argument passed. If you use positional arguments you must ensure that all parameters, up to the last positionally specified parameter, are used in the format string. This allows for the format string to be parsed for this information.