Bug 865 - [OprofileUI] oprofile-viewer crashed if oparchconv in oprofileui is not installed
Summary: [OprofileUI] oprofile-viewer crashed if oparchconv in oprofileui is not insta...
Status: RESOLVED FIXED
Alias: None
Product: ADT
Classification: Yocto Project Subprojects
Component: kernel analysis (show other bugs)
Version: 1.0
Hardware: x86 Multiple
: Medium normal
Target Milestone: 1.0 M4
Assignee: Lianhao Lu
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2011-03-14 01:59 UTC by Lianhao Lu
Modified: 2011-04-18 09:12 UTC (History)
4 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: ---


Attachments
oprofileui-Correctly-free-GError-struct.patch (880 bytes, patch)
2011-03-14 03:01 UTC, Lianhao Lu
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Lianhao Lu 2011-03-14 01:59:35 UTC
The oprofile-viewer needs oparchconv to convert the sample archive. If oparchconv is not installed(by running make install in oprofileui), it crashed with the following output:

Failed to execute child process "oparchconv" (No such file or directory)
*** glibc detected *** src/oprofile-viewer: free(): invalid pointer: 0x0000000002113e80 ***
======= Backtrace: =========
/lib/libc.so.6(+0x775b6)[0x7f559ff765b6]
/lib/libc.so.6(cfree+0x73)[0x7f559ff7ce83]
src/oprofile-viewer[0x40d14f]
src/oprofile-viewer[0x40d34d]
src/oprofile-viewer[0x4061d7]
src/oprofile-viewer[0x4094b9]
src/oprofile-viewer[0x409514]
src/oprofile-viewer[0x409826]
src/oprofile-viewer[0x4081be]
src/oprofile-viewer[0x4087bf]
/lib/libglib-2.0.so.0(g_main_context_dispatch+0x1f2)[0x7f55a04dd8c2]
/lib/libglib-2.0.so.0(+0x42748)[0x7f55a04e1748]
/lib/libglib-2.0.so.0(g_main_loop_run+0x195)[0x7f55a04e1c55]
/usr/lib/libgtk-x11-2.0.so.0(gtk_main+0xa7)[0x7f55a32e9bb7]
src/oprofile-viewer[0x407e43]
/lib/libc.so.6(__libc_start_main+0xfd)[0x7f559ff1dc4d]
src/oprofile-viewer[0x405e69]
======= Memory map: ========
00400000-00417000 r-xp 00000000 08:05 1704105                            /home/lulianhao/working/oprofileui/src/oprofile-viewer
00616000-00617000 r--p 00016000 08:05 1704105                            /home/lulianhao/working/oprofileui/src/oprofile-viewer
00617000-00618000 rw-p 00017000 08:05 1704105                            /home/lulianhao/working/oprofileui/src/oprofile-viewer
01f28000-02a5c000 rw-p 00000000 00:00 0                                  [heap]
7f558c000000-7f558c021000 rw-p 00000000 00:00 0 
7f558c021000-7f5590000000 ---p 00000000 00:00 0 
7f5590965000-7f559097b000 r-xp 00000000 08:07 4980815                    /lib/libgcc_s.so.1
7f559097b000-7f5590b7a000 ---p 00016000 08:07 4980815                    /lib/libgcc_s.so.1
7f5590b7a000-7f5590b7b000 r--p 00015000 08:07 4980815                    /lib/libgcc_s.so.1
7f5590b7b000-7f5590b7c000 rw-p 00016000 08:07 4980815                    /lib/libgcc_s.so.1
7f5590b8c000-7f5590b8d000 rw-p 00000000 00:00 0 
7f5590b8d000-7f5590c0d000 r--p 00000000 08:07 7997765                    /usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Oblique.ttf
7f5590c0d000-7f5590c99000 r--p 00000000 08:07 8027814                    /usr/share/fonts/truetype/ttf-dejavu/DejaVuSans-Bold.ttf
7f5590c99000-7f5590c9a000 ---p 00000000 00:00 0 
7f5590c9a000-7f559149a000 rw-p 00000000 00:00 0 
7f559149a000-7f559549b000 rw-s 00000000 00:10 15932298                   /dev/shm/pulse-shm-3056919471
7f559549b000-7f559565e000 r-xp 00000000 08:07 7868178                    /usr/lib/libvorbisenc.so.2.0.6
7f559565e000-7f559585e000 ---p 001c3000 08:07 7868178                    /usr/lib/libvorbisenc.so.2.0.6
7f559585e000-7f5595875000 r--p 001c3000 08:07 7868178                    /usr/lib/libvorbisenc.so.2.0.6
7f5595875000-7f5595876000 rw-p 001da000 08:07 7868178                    /usr/lib/libvorbisenc.so.2.0.6
7f5595876000-7f55958bf000 r-xp 00000000 08:07 7867155                    /usr/lib/libFLAC.so.8.2.0
7f55958bf000-7f5595abf000 ---p 00049000 08:07 7867155                    /usr/lib/libFLAC.so.8.2.0
7f5595abf000-7f5595ac0000 r--p 00049000 08:07 7867155                    /usr/lib/libFLAC.so.8.2.0
7f5595ac0000-7f5595ac1000 rw-p 0004a000 08:07 7867155                    /usr/lib/libFLAC.so.8.2.0
7f5595ac1000-7f5595b1f000 r-xp 00000000 08:07 7868087                    /usr/lib/libsndfile.so.1.0.21
7f5595b1f000-7f5595d1f000 ---p 0005e000 08:07 7868087                    /usr/lib/libsndfile.so.1.0.21
7f5595d1f000-7f5595d21000 r--p 0005e000 08:07 7868087                    /usr/lib/libsndfile.so.1.0.21
7f5595d21000-7f5595d22000 rw-p 00060000 08:07 7868087                    /usr/lib/libsndfile.so.1.0.21
7f5595d22000-7f5595d26000 rw-p 00000000 00:00 0 
7f5595d26000-7f5595d2f000 r-xp 00000000 08:07 4980925                    /lib/libwrap.so.0.7.6
7f5595d2f000-7f5595f2e000 ---p 00009000 08:07 4980925                    /lib/libwrap.so.0.7.6
7f5595f2e000-7f5595f2f000 r--p 00008000 08:07 4980925                    /lib/libwrap.so.0.7.6
7f5595f2f000-7f5595f30000 rw-p 00009000 08:07 4980925                    /lib/libwrap.so.0.7.6
7f5595f30000-7f5595f31000 rw-p 00000000 00:00 0 
7f5595f31000-7f5595f35000 r-xp 00000000 08:07 4980866                    /lib/libuuid.so.1.3.0
7f5595f35000-7f5596134000 ---p 00004000 08:07 4980866                    /lib/libuuid.so.1.3.0
7f5596134000-7f5596135000 r--p 00003000 08:07 4980866                    /lib/libuuid.so.1.3.0
7f5596135000-7f5596136000 rw-p 00004000 08:07 4980866                    /lib/libuuid.so.1.3.0
7f5596136000-7f5596181000 r-xp 00000000 08:07 7868028                    /usr/lib/libpulsecommon-0.9.21.so
7f5596181000-7f5596380000 ---p 0004b000 08:07 7868028                    /usr/lib/libpulsecommon-0.9.21.so
7f5596380000-7f5596381000 r--p 0004a000 08:07 7868028                    /usr/lib/libpulsecommon-0.9.21.so
7f5596381000-7f5596382000 rw-p 0004b000 08:07 7868028                    /usr/lib/libpulsecommon-0.9.21.so
7f5596382000-7f5596387000 r-xp 00000000 08:07 7867246                    /usr/lib/libXtst.so.6.1.0
7f5596387000-7f5596587000 ---p 00005000 08:07 7867246                    /usr/lib/libXtst.so.6.1.0
7f5596587000-7f5596588000 r--p 00005000 08:07 7867246                    /usr/lib/libXtst.so.6.1.0
7f5596588000-7f5596589000 rw-p 00006000 08:07 7867246                    /usr/lib/libXtst.so.6.1.0
7f5596589000-7f5596591000 r-xp 00000000 08:07 7867199                    /usr/lib/libSM.so.6.0.1
7f5596591000-7f5596790000 ---p 00008000 08:07 7867199                    /usr/lib/libSM.so.6.0.1
7f5596790000-7f5596791000 r--p 00007000 08:07 7867199                    /usr/lib/libSM.so.6.0.1
7f5596791000-7f5596792000 rw-p 00008000 08:07 7867199                    /usr/lib/libSM.so.6.0.1
7f5596792000-7f55967a9000 r-xp 00000000 08:07 7867170                    /usr/lib/libICE.so.6.3.0
7f55967a9000-7f55969a8000 ---p 00017000 08:07 7867170                    /usr/lib/libICE.so.6.3.0
7f55969a8000-7f55969a9000 r--p 00016000 08:07 7867170                    /usr/lib/libICE.so.6.3.0
7f55969a9000-7f55969aa000 rw-p 00017000 08:07 7867170                    /usr/lib/libICE.so.6.3.0
7f55969aa000-7f55969ad000 rw-p 00000000 00:00 0 
7f55969ad000-7f55969ed000 r-xp 00000000 08:07 7868027                    /usr/lib/libpulse.so.0.12.2
7f55969ed000-7f5596bed000 ---p 00040000 08:07 7868027                    /usr/lib/libpulse.so.0.12.2
7f5596bed000-7f5596bee000 r--p 00040000 08:07 7868027                    /usr/lib/libpulse.so.0.12.2Aborted

This indicates a buffer error in oprofile-viewer.

Ways to reproduce this bug:
1. launch a qemu with image poky-image-sato-sdk-qemux86-64
2. compile the oprofileui, but not "make install"
3. run the compiled oprofile-viewer
4. click "connect"->"start"->"stop"
Comment 1 Lianhao Lu 2011-03-14 03:01:48 UTC
Created attachment 110 [details]
oprofileui-Correctly-free-GError-struct.patch

This is the patch to fix the bug
Comment 2 Lianhao Lu 2011-03-14 03:03:20 UTC
Hi Josh,

Since I don't have the commit access, would you please review my patch and help me commit it into git? Thanks!
Comment 3 Joshua Lock - Disabled 2011-03-14 05:16:24 UTC
Pushed to oprofileui master: http://git.yoctoproject.org/cgit/cgit.cgi/oprofileui/commit/?id=2387488fb520725ca9cff888bc1ed25788276b13