Module Name: src
Committed By: dholland
Date: Sat May 29 20:32:18 UTC 2010
Modified Files:
src/lib/libc/time: strftime.3
Log Message:
Note briefly how to avoid the problem where 0 can be a valid successful
return as well as an error. Suggested by Robert Elz in follow up to PR 39392.
To generate a diff of this commit:
cvs rdiff -u -r1.25 -r1.26 src/lib/libc/time/strftime.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/time/strftime.3
diff -u src/lib/libc/time/strftime.3:1.25 src/lib/libc/time/strftime.3:1.26
--- src/lib/libc/time/strftime.3:1.25 Thu Apr 29 10:03:12 2010
+++ src/lib/libc/time/strftime.3 Sat May 29 20:32:18 2010
@@ -30,9 +30,9 @@
.\" SUCH DAMAGE.
.\"
.\" from: @(#)strftime.3 5.12 (Berkeley) 6/29/91
-.\" $NetBSD: strftime.3,v 1.25 2010/04/29 10:03:12 jruoho Exp $
+.\" $NetBSD: strftime.3,v 1.26 2010/05/29 20:32:18 dholland Exp $
.\"
-.Dd April 29, 2010
+.Dd May 29, 2010
.Dt STRFTIME 3
.Os
.Sh NAME
@@ -247,3 +247,6 @@
For example, in many locales
.Cm \&%p
yields an empty string.
+This problem can be avoided by inserting an extra space at the
+beginning of the format string and then skipping over it or removing
+it from the result.