Bug#735898: pavucontrol segmentation fault

John M. jwmwalrus at gmail.com
Sun Feb 23 04:06:08 UTC 2014


The full backtrace shows:


        (gdb) backtrace full
        #0  0x0000000000428d80 in read_callback (s=0xced1b0, length=4,
        userdata=0x92d600) at mainwindow.cc:385
                w = 0x92d600
                data = 0x0
                v = 7.1675486625997992e-317
                __PRETTY_FUNCTION__ = "void read_callback(pa_stream*,
        size_t, void*)"
        #1  0x00007ffff3adad8b in ?? ()
        from /usr/lib/x86_64-linux-gnu/libpulse.so.0
        No symbol table info available.
        #2  0x00007fffee0bb46d in ?? ()
        from /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-4.0.so
        No symbol table info available.
        #3  0x00007ffff3d17b77 in ?? ()
        from /usr/lib/x86_64-linux-gnu/libpulse-mainloop-glib.so.0
        No symbol table info available.
        #4  0x00007ffff3f63526 in g_main_context_dispatch ()
        from /lib/x86_64-linux-gnu/libglib-2.0.so.0
        No symbol table info available.
        #5  0x00007ffff3f63878 in ?? ()
        from /lib/x86_64-linux-gnu/libglib-2.0.so.0
        No symbol table info available.
        #6  0x00007ffff3f63b3a in g_main_loop_run ()
        from /lib/x86_64-linux-gnu/libglib-2.0.so.0
        No symbol table info available.
        #7  0x00007ffff59a444d in gtk_main ()
        from /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
        No symbol table info available.
        #8  0x00007ffff7a1a8f1 in Gtk::Main::run(Gtk::Window&) ()
        from /usr/lib/x86_64-linux-gnu/libgtkmm-3.0.so.1
        No symbol table info available.
        #9  0x0000000000438981 in main (argc=1, argv=0x7fffffffdb28) at
        pavucontrol.cc:670
                kit = <incomplete type>
                mainWindow = 0x92d600
                m = 0x8ee130
                options = <incomplete type>
                group = <incomplete type>
                entry = <incomplete type>
                __PRETTY_FUNCTION__ = "int main(int, char**)"


So indeed data is NULL.
--
John


On Sun, 2014-02-23 at 04:52 +0100, Vincent Lefevre wrote:

> On 2014-02-22 18:58:08 -0500, John M. wrote:
> > Program received signal SIGSEGV, Segmentation fault.
> > 0x0000000000428d80 in read_callback (s=0xcea800, length=4,
> > userdata=0x9561b0) at mainwindow.cc:385
> > 385	    v = ((const float*) data)[length / sizeof(float) -1];
> [...]
> 
> Thanks. The src/mainwindow.cc file contains:
> 
>     if (pa_stream_peek(s, &data, &length) < 0) {
>         show_error(_("Failed to read data from stream"));
>         return;
>     }
> 
>     assert(length > 0);
>     assert(length % sizeof(float) == 0);
> 
>     v = ((const float*) data)[length / sizeof(float) -1];
> 
> And according to the pa_stream_peek documentation
> 
>   http://freedesktop.org/software/pulseaudio/doxygen/stream_8h.html#ac2838c449cde56e169224d7fe3d00824
> 
> "If there is no data at the current read index, it means that either
> the buffer is empty or it contains a hole (that is, the write index
> is ahead of the read index but there's no data where the read index
> points at). If the buffer is empty, data will be NULL and nbytes will
> be 0. If there is a hole, data will be NULL and nbytes will contain
> the length of the hole."
> 
> data can be NULL and the code is obviously buggy.
> 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.alioth.debian.org/pipermail/pkg-pulseaudio-devel/attachments/20140222/6ddb0c50/attachment.html>
-------------- next part --------------
Starting program: /usr/bin/pavucontrol 
warning: no loadable sections found in added symbol-file system-supplied DSO at 0x7ffff7ffa000
warning: Could not load shared library symbols for linux-vdso.so.1.
Do you need "set solib-search-path" or "set sysroot"?
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe874a700 (LWP 31513)]

Program received signal SIGSEGV, Segmentation fault.
0x0000000000428d80 in read_callback (s=0xceda40, length=4, userdata=0x956200) at mainwindow.cc:385
385	    v = ((const float*) data)[length / sizeof(float) -1];
#0  0x0000000000428d80 in read_callback (s=0xceda40, length=4, userdata=0x956200) at mainwindow.cc:385
        w = 0x956200
        data = 0x0
        v = 6.9063816096829495e-317
        __PRETTY_FUNCTION__ = "void read_callback(pa_stream*, size_t, void*)"
#1  0x00007ffff3adad8b in ?? () from /usr/lib/x86_64-linux-gnu/libpulse.so.0
No symbol table info available.
#2  0x00007fffee0bb46d in ?? () from /usr/lib/x86_64-linux-gnu/pulseaudio/libpulsecommon-4.0.so
No symbol table info available.
#3  0x00007ffff3d17b77 in ?? () from /usr/lib/x86_64-linux-gnu/libpulse-mainloop-glib.so.0
No symbol table info available.
#4  0x00007ffff3f63526 in g_main_context_dispatch () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#5  0x00007ffff3f63878 in ?? () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#6  0x00007ffff3f63b3a in g_main_loop_run () from /lib/x86_64-linux-gnu/libglib-2.0.so.0
No symbol table info available.
#7  0x00007ffff59a444d in gtk_main () from /usr/lib/x86_64-linux-gnu/libgtk-3.so.0
No symbol table info available.
#8  0x00007ffff7a1a8f1 in Gtk::Main::run(Gtk::Window&) () from /usr/lib/x86_64-linux-gnu/libgtkmm-3.0.so.1
No symbol table info available.
#9  0x0000000000438981 in main (argc=1, argv=0x7fffffffdb28) at pavucontrol.cc:670
        kit = <incomplete type>
        mainWindow = 0x956200
        m = 0x937230
        options = <incomplete type>
        group = <incomplete type>
        entry = <incomplete type>
        __PRETTY_FUNCTION__ = "int main(int, char**)"
Kill the program being debugged? (y or n) Please answer y or n.
Kill the program being debugged? (y or n) 


More information about the pkg-pulseaudio-devel mailing list