The patch is agains 2.2.10, but I don't think anything has touched
this file for quite some time, so it'll probably go cleanly
everywhere. Please feel free to apply, test, flame etc. If feedback
is positive I'll send it to Alan and Linus with a suitably grovelling
request for inclusion.
Sean
--- linux.vanilla/lib/vsprintf.c Wed Jul 21 12:05:34 1999
+++ linux/lib/vsprintf.c Fri Jul 23 17:25:48 1999
@@ -156,7 +156,9 @@
int precision; /* min. # of digits for integers; max
number of chars for from string */
int qualifier; /* 'h', 'l', or 'L' for integer fields */
+ /* 'Z' support added 23/7/1999 S.H. */
+
for (str=buf ; *fmt ; ++fmt) {
if (*fmt != '%') {
*str++ = *fmt;
@@ -206,7 +208,7 @@
/* get the conversion qualifier */
qualifier = -1;
- if (*fmt == 'h' || *fmt == 'l' || *fmt == 'L') {
+ if (*fmt == 'h' || *fmt == 'l' || *fmt == 'L' || *fmt =='Z') {
qualifier = *fmt;
++fmt;
}
@@ -255,6 +257,9 @@
if (qualifier == 'l') {
long * ip = va_arg(args, long *);
*ip = (str - buf);
+ } else if (qualifier == 'Z') {
+ size_t * ip = va_arg(args, size_t *);
+ *ip = (str - buf);
} else {
int * ip = va_arg(args, int *);
*ip = (str - buf);
@@ -292,6 +297,8 @@
}
if (qualifier == 'l')
num = va_arg(args, unsigned long);
+ else if (qualifier == 'Z')
+ num = va_arg(args, size_t);
else if (qualifier == 'h') {
num = (unsigned short) va_arg(args, int);
if (flags & SIGN)
----- End forwarded message -----
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/