diff options
author | Alexey Dobriyan <adobriyan@gmail.com> | 2006-12-06 23:37:04 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-07 11:39:35 -0500 |
commit | 4a6e617a4bec9fb2ee4a16cf59565b2af5049e12 (patch) | |
tree | 4d69b8da779c58b506efe8f3fcae48d7b3c7bb4d /fs/jfs | |
parent | e0980dafa329d33bb88edc8a3ef9fab4e070590c (diff) |
[PATCH] fs/*: trivial vsnprintf() conversion
It would very lame to get buffer overflow via one of the following.
Signed-off-by: Alexey Dobriyan <adobriyan@gmail.com>
Cc: Dave Kleikamp <shaggy@austin.ibm.com>
Cc: Mark Fasheh <mark.fasheh@oracle.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/jfs')
-rw-r--r-- | fs/jfs/super.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/jfs/super.c b/fs/jfs/super.c index ca3e19128532..846ac8f34513 100644 --- a/fs/jfs/super.c +++ b/fs/jfs/super.c | |||
@@ -93,7 +93,7 @@ void jfs_error(struct super_block *sb, const char * function, ...) | |||
93 | va_list args; | 93 | va_list args; |
94 | 94 | ||
95 | va_start(args, function); | 95 | va_start(args, function); |
96 | vsprintf(error_buf, function, args); | 96 | vsnprintf(error_buf, sizeof(error_buf), function, args); |
97 | va_end(args); | 97 | va_end(args); |
98 | 98 | ||
99 | printk(KERN_ERR "ERROR: (device %s): %s\n", sb->s_id, error_buf); | 99 | printk(KERN_ERR "ERROR: (device %s): %s\n", sb->s_id, error_buf); |