From: Mariusz Kozlowski When buf_check_overflow() returns != 0 we will hit kfree(ERR_PTR(err)) and it will not be happy about it. Signed-off-by: Mariusz Kozlowski Cc: Latchesar Ionkov Cc: Eric Van Hensbergen Cc: Andrew Morton Signed-off-by: Andrew Morton --- net/9p/conv.c | 1 + 1 files changed, 1 insertion(+) diff -puN net/9p/conv.c~fs-9p-convc-error-path-fix net/9p/conv.c --- a/net/9p/conv.c~fs-9p-convc-error-path-fix +++ a/net/9p/conv.c @@ -763,6 +763,7 @@ struct p9_fcall *p9_create_twrite(u32 fi if (err) { kfree(fc); fc = ERR_PTR(err); + goto error; } if (buf_check_overflow(bufp)) { _