]> git.ipfire.org Git - thirdparty/kernel/stable.git/commit
UBIFS: fix complaints about too small debug buffer size
authorArtem Bityutskiy <artem.bityutskiy@linux.intel.com>
Tue, 21 Aug 2012 18:50:58 +0000 (21:50 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 14 Sep 2012 16:59:26 +0000 (09:59 -0700)
commit7c3b873743b682dc1c66cac3eb4fdcba3f567a3a
tree1075811fe1b1214d177d5f1c217eeaaab42409a9
parent75a8ac4c5552f71f5a1db27a3232e6e389a1274c
UBIFS: fix complaints about too small debug buffer size

commit 65b455b123c7e2b835a0b7148f9bae584f95000e upstream.

When debugging is enabled, we use a temporary on-stack buffer for formatting
the key strings like "(11368871, direntry, 0xcd0750)". The buffer size is
32 bytes and sometimes it is not enough to fit the key string - e.g., when
inode numbers are high. This is not fatal, but the key strings are incomplete
and UBIFS complains like this:

UBIFS assert failed in dbg_snprintf_key at 137 (pid 1)

This is a regression caused by "515315a UBIFS: fix key printing".

Fix the issue by increasing the buffer to 48 bytes.

Reported-by: Michael Hench <michaelhench@gmail.com>
Signed-off-by: Artem Bityutskiy <artem.bityutskiy@linux.intel.com>
Tested-by: Michael Hench <michaelhench@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
fs/ubifs/debug.h