summaryrefslogtreecommitdiffstats
path: root/lib/interval_tree.c
diff options
context:
space:
mode:
authorAndy Shevchenko2015-02-13 00:02:29 +0100
committerLinus Torvalds2015-02-13 03:54:15 +0100
commit114fc1afb2de7dec40da137dc2a55cd38fc220f2 (patch)
tree414c7731a5a4743cbdba6583a1b79f3723ec190d /lib/interval_tree.c
parenthexdump: do a few calculations ahead (diff)
downloadkernel-qcow2-linux-114fc1afb2de7dec40da137dc2a55cd38fc220f2.tar.gz
kernel-qcow2-linux-114fc1afb2de7dec40da137dc2a55cd38fc220f2.tar.xz
kernel-qcow2-linux-114fc1afb2de7dec40da137dc2a55cd38fc220f2.zip
hexdump: make it return number of bytes placed in buffer
This patch makes hexdump return the number of bytes placed in the buffer excluding trailing NUL. In the case of overflow it returns the desired amount of bytes to produce the entire dump. Thus, it mimics snprintf(). This will be useful for users that would like to repeat with a bigger buffer. [akpm@linux-foundation.org: fix printk warning] Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'lib/interval_tree.c')
0 files changed, 0 insertions, 0 deletions