tools lib traceevent kbuffer: Remove extra update to data pointer in PADDING
authorSteven Rostedt (Red Hat) <rostedt@goodmis.org>
Tue, 24 Mar 2015 13:57:55 +0000 (09:57 -0400)
committerArnaldo Carvalho de Melo <acme@redhat.com>
Tue, 24 Mar 2015 15:22:04 +0000 (12:22 -0300)
When a event PADDING is hit (a deleted event that is still in the ring
buffer), translate_data() sets the length of the padding and also updates
the data pointer which is passed back to the caller.

This is unneeded because the caller also updates the data pointer with
the passed back length. translate_data() should not update the pointer,
only set the length.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
Cc: Andrew Morton <akpm@linux-foundation.org>
Cc: Jiri Olsa <jolsa@redhat.com>
Cc: Namhyung Kim <namhyung@kernel.org>
Cc: stable@vger.kernel.org # 3.12+
Link: http://lkml.kernel.org/r/20150324135923.461431960@goodmis.org
Signed-off-by: Arnaldo Carvalho de Melo <acme@redhat.com>
tools/lib/traceevent/kbuffer-parse.c

index dcc665228c71fd09f7b39c2486063d98f7176445..deb3569ab004ffc8904121695773ffd02d239140 100644 (file)
@@ -372,7 +372,6 @@ translate_data(struct kbuffer *kbuf, void *data, void **rptr,
        switch (type_len) {
        case KBUFFER_TYPE_PADDING:
                *length = read_4(kbuf, data);
-               data += *length;
                break;
 
        case KBUFFER_TYPE_TIME_EXTEND: