• Arnaldo Carvalho de Melo's avatar
    perf record: Delay setting the header writing atexit call · 712a4b60
    Arnaldo Carvalho de Melo authored
    While testing the --filter option I noticed that we were writing lots of
    unneeded stuff to the perf.data header when the filter ioctl fails, so
    move the atexit(atexit_header) call to after we create the counters
    successfully.
    
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Ingo Molnar <mingo@elte.hu>
    Cc: Mike Galbraith <efault@gmx.de>
    Cc: Paul Mackerras <paulus@samba.org>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Stephane Eranian <eranian@google.com>
    Cc: Tom Zanussi <tzanussi@gmail.com>
    LKML-Reference: <new-submission>
    Signed-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
    712a4b60
builtin-record.c 22.6 KB