patch-2.3.41 linux/lib/vsprintf.c
Next file: linux/mm/filemap.c
Previous file: linux/kernel/sysctl.c
Back to the patch index
Back to the overall index
- Lines: 35
- Date:
Wed Jan 26 12:29:12 2000
- Orig file:
v2.3.40/linux/lib/vsprintf.c
- Orig date:
Thu Nov 11 20:11:54 1999
diff -u --recursive --new-file v2.3.40/linux/lib/vsprintf.c linux/lib/vsprintf.c
@@ -152,6 +152,7 @@
number of chars for from string */
int qualifier; /* 'h', 'l', or 'L' for integer fields */
/* 'z' support added 23/7/1999 S.H. */
+ /* 'z' changed to 'Z' --davidm 1/25/99 */
for (str=buf ; *fmt ; ++fmt) {
@@ -203,7 +204,7 @@
/* get the conversion qualifier */
qualifier = -1;
- if (*fmt == 'h' || *fmt == 'l' || *fmt == 'L' || *fmt =='z') {
+ if (*fmt == 'h' || *fmt == 'l' || *fmt == 'L' || *fmt =='Z') {
qualifier = *fmt;
++fmt;
}
@@ -252,7 +253,7 @@
if (qualifier == 'l') {
long * ip = va_arg(args, long *);
*ip = (str - buf);
- } else if (qualifier == 'z') {
+ } else if (qualifier == 'Z') {
size_t * ip = va_arg(args, size_t *);
*ip = (str - buf);
} else {
@@ -296,7 +297,7 @@
num = va_arg(args, unsigned long);
if (flags & SIGN)
num = (signed long) num;
- } else if (qualifier == 'z') {
+ } else if (qualifier == 'Z') {
num = va_arg(args, size_t);
} else if (qualifier == 'h') {
num = (unsigned short) va_arg(args, int);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)