]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
[PATCH] v9fs: make conv functions to check for conv buffer overflow
authorLatchesar Ionkov <lucho@ionkov.net>
Fri, 23 Sep 2005 04:43:48 +0000 (21:43 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Fri, 23 Sep 2005 05:17:33 +0000 (22:17 -0700)
commitd06a8fb130085c9f61e4c1a40445163087ecf89f
treec98595f83201adcd791ef9d3509aa1f157f3dfa2
parent89559a6119e9779c732fdc7aef5e175bf090dd69
[PATCH] v9fs: make conv functions to check for conv buffer overflow

buf_check_size function checks if the conv buffer has enough space for the
performed operation, but it doesn't return the result back to the calling
function, only logs an error in the log.

The report-back-error functionality was lost when buf_check_size was
converted from macro to inline function. The return in the macro used to
exit from the functions that include it, after the conversion it just exits
from the inline function itself.

The patch makes buf_check_size to return flag and all functions that use
it check if they should perform the operation, or exit.

Signed-off-by: Latchesar Ionkov <lucho@ionkov.net>
Cc: Eric Van Hensbergen <ericvh@gmail.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/9p/conv.c