This is the mail archive of the systemtap@sourceware.org mailing list for the systemtap project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug lket/4552] New: lket-b2a crashes (the lket-b2a code needs to be more robust)


During the testing the lket tests fails.

FAIL: systemtap.samples/lket(lket-b2a runtime)

Taking a closer look at what is going on the lket-b2a segfaults.

(gdb) run -f stpd_cpu*
Starting program: /home/wcohen/stap_testing_200705251949/install/bin/lket-b2a -f
stpd_cpu*

Program received signal SIGSEGV, Segmentation fault.
0x0804a8d6 in dump_data (header=
      {total_size = 16703, sys_size = 20026, microsecond = 7887296222732963401,
tid_pid = 7286936824557233506, aggr = 3467835980590838386}, infp=0x8f6e658)
    at /home/wcohen/stap_testing_200705251949/src/runtime/lket/b2a/lket_b2a.c:649
649                             fprintf(outfp, "EVT_NAME:%s ",
events_des[_HOOKID_REGSYSEVT][grpid][hookid]->description);
(gdb) print _HOOKID_REGSYSEVT 
$1 = 1
(gdb) print grpid 
$2 = 114
(gdb) print hookid 
$3 = 111
(gdb) print events_des  [_HOOKID_REGSYSEVT][grpid ][hookid ]
$4 = (event_desc *) 0x0


Looking through the lket_b2a.c code there doesn't seem to be any checking to
make sure that the events_des elements are set up correctly. Thus, null pointers
can be accessed in the manner above, causing the program to seg fault.

-- 
           Summary: lket-b2a crashes (the lket-b2a code needs to be more
                    robust)
           Product: systemtap
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: lket
        AssignedTo: systemtap at sources dot redhat dot com
        ReportedBy: wcohen at redhat dot com
  GCC host triplet: i686


http://sourceware.org/bugzilla/show_bug.cgi?id=4552

------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]