gdb works abnormally when debug the libvirt.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When I  to use gdb to check whether qemuMonitorJSONIOProcessEvent processes the Event that I expect.

but the gdb works  abnormally.
I list the the position of the source file by gdb. It is the correct function qemuMonitorJSONIOProcessEvent.
However I set break point on this  position. then "info b", it is the wrong function qemuMonitorJSONIOProcess.

I debug my libvirt on Ubuntu 11.10 this time.But I have set  a break point at this function on redhat 6.0 before, it can work well.

My gcc version is: gcc (Ubuntu/Linaro 4.6.1-9ubuntu3) 4.6.1
My gdb version is: GNU gdb (Ubuntu/Linaro 7.3-0ubuntu2) 7.3-2011.08

here is the info:

(gdb) list qemu/qemu_monitor_json.c:88
83    qemuMonitorJSONIOProcessEvent(qemuMonitorPtr mon,
84                                  virJSONValuePtr obj)
85    {
86        const char *type;
87        int i;
88        int findEventFlag = -1;
89        VIR_DEBUG("mon=%p obj=%p", mon, obj);
90   
91        type = virJSONValueObjectGetString(obj, "event");
92        if (!type) {



(gdb) b qemu/qemu_monitor_json.c:88
Breakpoint 5 at 0x4a18d4: file qemu/qemu_monitor_json.c, line 88.
(gdb) info b
Num     Type           Disp Enb Address            What
5       breakpoint     keep y   0x00000000004a18d4 in qemuMonitorJSONIOProcess at qemu/qemu_monitor_json.c:88
(gdb)

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]