FS#9917 - wvdial segfaults and can not be compiled with gcc-4.3.0 in testing

Attached to Project: Arch Linux
Opened by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 15:20 GMT
Last edited by Jan de Groot (JGC) - Sunday, 23 March 2008, 22:09 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To No-one
Architecture All
Severity Medium
Priority Normal
Reported Version 2007.08-2
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 1
Private No

Details

Description:
wvdial segfaulted for me 4 times on 5, while I was able to connect with the clean pppd. I was using it with an umts modem and the following /etc/wvdial.conf (basically a translation of the working pppd options):
[Dialer Defaults]
Modem = /dev/noz0
ISDN = off
Modem Type = Analog Modem
Baud = 460800
Init = ATX3
Init2 = AT&F Q0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
Init3 = at+cgdcont=1,"IP","internet.wind"
Init4 =
Init5 =
Init6 =
Init7 =
Init8 =
Init9 =
Phone = *99***1#
Phone1 = *99***1#
Phone2 =
Phone3 =
Phone4 =
Dial Prefix =
Dial Attempts = 20
Dial Command = ATM1L3DT
Ask Password = off
Password = anon
Username = anon
Auto Reconnect = off
Abort on Busy = off
Carrier Check = on
Check Def Route = on
Abort on No Dialtone = on
Stupid Mode = on
Idle Seconds = 0
Auto DNS = on

You can find attached the strace.

I solved the issue recompiling both wvstreams and wvdial. However, they compile only with gcc-4.2.1 in the core repo. With gcc-4.3.0 in testing, wvstreams fails with:

compiling uniconf/uniconf.o...
In file included from ./include/uniconf.h:10,
from uniconf/uniconf.cc:7:
./include/uniconfkey.h: In member function 'UniConfKey UniConfKey::last(int) const':
./include/uniconfkey.h:330: error: 'INT_MAX' was not declared in this scope
./include/uniconfkey.h: In member function 'UniConfKey UniConfKey::removefirst(int) const':
./include/uniconfkey.h:341: error: 'INT_MAX' was not declared in this scope
make: *** [uniconf/uniconf.o] Error 1
make: *** Waiting for unfinished jobs....
Additional info:
* package version(s)
* config and/or log files etc.

Wvdial fails with:

compiling wvdialbrain.o...
In file included from /usr/include/wvstreams/uniconf.h:10,
from /usr/include/wvstreams/uniconfroot.h:10,
from /usr/include/wvstreams/wvconfemu.h:10,
from wvpapchap.h:12,
from wvpapchap.cc:9:
/usr/include/wvstreams/uniconfkey.h: In member function 'UniConfKey UniConfKey::last(int) const':
/usr/include/wvstreams/uniconfkey.h:330: error: 'INT_MAX' was not declared in this scope
/usr/include/wvstreams/uniconfkey.h: In member function 'UniConfKey UniConfKey::removefirst(int) const':
/usr/include/wvstreams/uniconfkey.h:341: error: 'INT_MAX' was not declared in this scope
wvpapchap.cc: In member function 'void WvPapChap::put_secret(WvString, WvString, WvString)':
wvpapchap.cc:29: warning: deprecated conversion from string constant to 'char*'
wvpapchap.cc:31: warning: deprecated conversion from string constant to 'char*'
wvpapchap.cc:36: warning: deprecated conversion from string constant to 'char*'
wvpapchap.cc:38: warning: deprecated conversion from string constant to 'char*'
make: *** [wvpapchap.o] Error 1
make: *** Waiting for unfinished jobs....

Steps to reproduce: use the testing repo, run wvdial

Solution: recompile wvstreams and wvdial (but not with the gcc in core).
This task depends upon

Closed by  Jan de Groot (JGC)
Sunday, 23 March 2008, 22:09 GMT
Reason for closing:  Fixed
Additional comments about closing:  Fixed in 2.7-9, which is in testing for both architectures at this moment.
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 15:21 GMT
Sorry, in the last line I meant: "not with the gcc in testing".
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 15:34 GMT
Well, it seems that, while I was posting this bug, gcc-4.3.0 entered the core repo, so the bug now concerns gcc in core...
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 17:22 GMT
Recompiled wvstreams and wvdial with gcc 4.3, added a patch to wvstreams to fix compilation. Please confirm this as fixed or not, as I'm far away from any dialup line here.
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 19:29 GMT
Well, it seems that, while I was posting this bug, gcc-4.3.0 entered the core repo, so the bug now concerns gcc in core...
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 19:30 GMT
Sorry, I sent again erroneously a previous comment. I am going to test and will report later the results
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 19:53 GMT
No, sorry, the compilations are fine, but wvdial segfaults again. It seems related to the new glibc: if I downgrade to the old glibc-2.7-7, it does not segfault; if I reupgrade to glibc-2.7-8, it segfaults again.
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 20:04 GMT
Can you rebuild wvdial and wvstreams with " -g" appended to both CFLAGS and CXXFLAGS in your makepkg.conf? Make sure you build with makepkg -n, as the resulting binaries shouldn't get stripped. After installing both packages, could you try running wvdial through gdb or valgrind?
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 20:48 GMT
I rebuilt both with the -O0 -g flags and the strip option disabled in /etc/makepkg.conf (makepkg -n perhaps does not exist any more).

I have no great experience with gdb, what I have done is entering 'gdb wvdial' and then I gave the run command. The output is the normal wvdial output when it segfaults and an additional line:

Starting program: /usr/bin/wvdial
--> WvDial: Internet dialer version 1.60
--> Cannot get information for serial port.
--> Initializing modem.
--> Sending: ATX3
ATX3
OK
--> Sending: AT&F Q0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
AT&F Q0 V1 E1 S0=0 &C1 &D2 +FCLASS=0
OK
--> Sending: at+cgdcont=1,"IP","internet.wind"
at+cgdcont=1,"IP","internet.wind"
OK
--> Modem initialized.

Program received signal SIGSEGV, Segmentation fault.
0xa7b7085f in makecontext () from /lib/libc.so.6

Let me know if I should do something more with gdb or valgrind.
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 21:04 GMT
could you attach the output of both valgrind and the "bt" command from gdb? If "bt full" gives useful information, can you attach that one too?
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 21:06 GMT
http://bugs.gentoo.org/show_bug.cgi?id=206579 looks like the same bugreport though.
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 21:13 GMT
The output of valgrind --leak-check=full --show-reachable=yes wvdial is the following:

==32659== Use of uninitialised value of size 4
==32659== at 0x43025B9: WvTaskMan::do_task() (wvtask.cc:492)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x430261F: WvTaskMan::do_task() (wvtask.cc:494)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x4302629: WvTaskMan::do_task() (wvtask.cc:494)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x439B724: getcontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386) ==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270) ==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x439B75B: getcontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Conditional jump or move depends on uninitialised value(s)
==32659== at 0x439B75D: getcontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Syscall param sigprocmask(oldset) contains uninitialised byte(s)
==32659== at 0x439B776: getcontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x4302645: WvTaskMan::do_task() (wvtask.cc:506)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Use of uninitialised value of size 4
==32659== at 0x439B838: makecontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== Invalid write of size 4
==32659== at 0x439B85F: makecontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659== Address 0xaff20004 is not stack'd, malloc'd or (recently) free'd
==32659==
==32659== Process terminating with default action of signal 11 (SIGSEGV)
==32659== Access not within mapped region at address 0xAFF20004
==32659== at 0x439B85F: makecontext (in /lib/libc-2.7.so)
==32659== by 0x43028F4: WvTaskMan::_stackmaster() (wvtask.cc:429)
==32659== by 0x43029DD: WvTaskMan::stackmaster() (wvtask.cc:386)
==32659== by 0x4302435: WvTaskMan::run(WvTask&, int) (wvtask.cc:270)
==32659==
==32659== ERROR SUMMARY: 10 errors from 10 contexts (suppressed: 41 from 1)
==32659== malloc/free: in use at exit: 40,743 bytes in 594 blocks.
==32659== malloc/free: 4,699 allocs, 4,105 frees, 144,429 bytes allocated.
==32659== For counts of detected errors, rerun with: -v
==32659== searching for pointers to 594 not-freed blocks.
==32659== checked 1,690,116 bytes.
==32659==
==32659==
==32659== 12 bytes in 3 blocks are still reachable in loss record 1 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x44041D7: re_node_set_init_copy (in /lib/libc-2.7.so)
==32659== by 0x4406D74: re_acquire_state_context (in /lib/libc-2.7.so)
==32659== by 0x440FF34: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 64 bytes in 8 blocks are still reachable in loss record 2 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4403708: link_nfa_nodes (in /lib/libc-2.7.so)
==32659== by 0x440211B: preorder (in /lib/libc-2.7.so)
==32659== by 0x440FAF9: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 120 bytes in 1 blocks are still reachable in loss record 3 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4192607: WvArgsData::argp_init(unsigned) (wvargs.cc:636)
==32659== by 0x4192695: WvArgsData::argp_build() (wvargs.cc:645)
==32659== by 0x419440B: WvArgs::process(int, char**, WvStringList*) (wvargs.cc:785)
==32659== by 0x804CC9E: main (wvdial.cc:133)
==32659==
==32659==
==32659== 160 bytes in 5 blocks are still reachable in loss record 4 of 17
==32659== at 0x4021BDE: calloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440D921: parse_bracket_exp (in /lib/libc-2.7.so)
==32659== by 0x440EC9F: parse_expression (in /lib/libc-2.7.so)
==32659== by 0x440F47E: parse_branch (in /lib/libc-2.7.so)
==32659== by 0x440F528: parse_reg_exp (in /lib/libc-2.7.so)
==32659== by 0x440F906: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CE6: WvDialMon::WvDialMon() (wvdialmon.cc:40)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 168 bytes in 3 blocks are still reachable in loss record 5 of 17
==32659== at 0x4021BDE: calloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4406D5B: re_acquire_state_context (in /lib/libc-2.7.so)
==32659== by 0x440FF34: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 252 bytes in 3 blocks are still reachable in loss record 6 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F982: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 260 bytes in 49 blocks are still reachable in loss record 7 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4402B0C: re_node_set_alloc (in /lib/libc-2.7.so)
==32659== by 0x4404BC0: calc_eclosure_iter (in /lib/libc-2.7.so)
==32659== by 0x440FB7F: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 444 bytes in 6 blocks are still reachable in loss record 8 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4022BFC: realloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4410378: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 504 bytes in 3 blocks are still reachable in loss record 9 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F6AD: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 504 bytes in 3 blocks are still reachable in loss record 9 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F6AD: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 756 bytes in 3 blocks are still reachable in loss record 10 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F9C1: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 756 bytes in 3 blocks are still reachable in loss record 11 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F9AD: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 768 bytes in 3 blocks are still reachable in loss record 12 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x4411442: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 1,040 bytes in 2 blocks are still reachable in loss record 13 of 17
==32659== at 0x4021BDE: calloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x438E4C1: __new_exitfn (in /lib/libc-2.7.so)
==32659== by 0x438E59F: __cxa_atexit (in /lib/libc-2.7.so)
==32659== by 0x414FABC: _GLOBAL__I_wvhttpcomponent.cc (wvhttppool.h:28)
==32659== by 0x415F59C: (within /usr/lib/libwvstreams.so.4.4)
==32659== by 0x40ECFE3: (within /usr/lib/libwvstreams.so.4.4)
==32659== by 0x400E363: call_init (in /lib/ld-2.7.so)
==32659== by 0x400E493: _dl_init (in /lib/ld-2.7.so)
==32659== by 0x400084E: (within /lib/ld-2.7.so)
==32659==
==32659==
==32659== 1,152 bytes in 3 blocks are still reachable in loss record 14 of 17
==32659== at 0x4021BDE: calloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x440F6E1: re_compile_internal (in /lib/libc-2.7.so)
==32659== by 0x44114B1: regcomp (in /lib/libc-2.7.so)
==32659== by 0x8059CC9: WvDialMon::WvDialMon() (wvdialmon.cc:39)
==32659== by 0x8051272: WvDialer::WvDialer(WvConfEmu&, WvStringList*, bool) (wvdialer.cc:63)
==32659== by 0x804CFF8: main (wvdial.cc:212)
==32659==
==32659==
==32659== 3,926 bytes in 174 blocks are still reachable in loss record 15 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x42FA447: WvFastString::alloc(unsigned) (wvstring.cc:269)
==32659== by 0x42FB358: WvString::unique() (wvstring.cc:310)
==32659== by 0x42F8F91: WvMonikerBase::WvMonikerBase(_GUID const&, WvFastString const&, void* (*)(WvFastString const&)) (wvstring.h:355)
==32659== by 0x4329E8B: _GLOBAL__I___wv_link_WvConStream (wvmoniker.h:67)
==32659== by 0x43365EC: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x42F1547: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x400E363: call_init (in /lib/ld-2.7.so)
==32659== by 0x400E493: _dl_init (in /lib/ld-2.7.so)
==32659== by 0x400084E: (within /lib/ld-2.7.so)
==32659==
==32659==
==32659== 13,145 bytes in 280 blocks are still reachable in loss record 16 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x432C048: operator new(unsigned) (in /usr/lib/libwvbase.so.4.4)
==32659== by 0x42F8BAC: WvMonikerRegistry::find_reg(_GUID const&) (wvmoniker.cc:98)
==32659== by 0x42F8F9C: WvMonikerBase::WvMonikerBase(_GUID const&, WvFastString const&, void* (*)(WvFastString const&)) (wvmoniker.cc:170)
==32659== by 0x4329E8B: _GLOBAL__I___wv_link_WvConStream (wvmoniker.h:67)
==32659== by 0x43365EC: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x42F1547: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x400E363: call_init (in /lib/ld-2.7.so)
==32659== by 0x400E493: _dl_init (in /lib/ld-2.7.so)
==32659== by 0x400084E: (within /lib/ld-2.7.so)
==32659==
==32659==
==32659== 17,216 bytes in 45 blocks are possibly lost in loss record 17 of 17
==32659== at 0x4022AB8: malloc (in /usr/lib/valgrind/x86-linux/vgpreload_memcheck.so)
==32659== by 0x432C048: operator new(unsigned) (in /usr/lib/libwvbase.so.4.4)
==32659== by 0x432C0EC: operator new[](unsigned) (in /usr/lib/libwvbase.so.4.4)
==32659== by 0x430650E: WvStreamsDebugger::add_command(WvFastString const&, WvCallback<void*, WvFastString const&, E, E, E, E, E, E, E>, WvCallback<WvString, WvFastString const&, WvStringList&, WvCallback<void, WvFastString const&, WvStringList&, E, E, E, E, E, E>, void*, E, E, E, E>, WvCallback<void, WvFastString const&, void*, E, E, E, E, E, E>) (wvhashtable.h:189)
==32659== by 0x430A8C2: WvStream::add_debugger_commands() (wvstream.cc:211)
==32659== by 0x430BE5B: WvStream::WvStream() (wvstream.cc:243)
==32659== by 0x42F7951: WvFdStream::WvFdStream(int, int) (wvfdstream.cc:62)
==32659== by 0x4329DE7: _WvConStream::_WvConStream(int, int, WvFastString const&) (wvconstream.cc:52)
==32659== by 0x4329FF8: _GLOBAL__I___wv_link_WvConStream (wvconstream.cc:95)
==32659== by 0x43365EC: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x42F1547: (within /usr/lib/libwvbase.so.4.4)
==32659== by 0x400E363: call_init (in /lib/ld-2.7.so)
==32659==
==32659== LEAK SUMMARY:
==32659== definitely lost: 0 bytes in 0 blocks.
==32659== possibly lost: 17,216 bytes in 45 blocks.
==32659== still reachable: 23,527 bytes in 549 blocks.
==32659== suppressed: 0 bytes in 0 blocks.
zsh: segmentation fault valgrind --leak-check=full --show-reachable=yes wvdial
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 21:31 GMT
I see some invalid reads in the makecontext/getcontext function in your backtrace. In the most recent version of glibc, we, and also gentoo as referenced in this bugreport, added a patch from upstream CVS to align the stack for that function. I'm building a new glibc package you could try to see if it works. What architecture do you use? i686 or amd64?
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 21:32 GMT
The output of bt full in gdb is:

#0 0xa7b7e85f in makecontext () from /lib/libc.so.6
No symbol table info available.
#1 0xa7cd6689 in WvTaskMan::do_task () at utils/wvtask.cc:513
task = (WvTask *) 0x806b268
__PRETTY_FUNCTION__ = "static void WvTaskMan::do_task()"
#2 0xa7cd68f5 in WvTaskMan::_stackmaster () at utils/wvtask.cc:429
__PRETTY_FUNCTION__ = "static void WvTaskMan::_stackmaster()"
#3 0xa7cd69de in WvTaskMan::stackmaster () at utils/wvtask.cc:386
No locals.
#4 0xa7cd6436 in WvTaskMan::run (task=@0x646e6500, val=131072) at utils/wvtask.cc:270
newval = <value optimized out>
__PRETTY_FUNCTION__ = "static int WvTaskMan::run(WvTask&, int)"
Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 21:33 GMT
My architexture is i686
Comment by Jan de Groot (JGC) - Sunday, 23 March 2008, 21:35 GMT Comment by Giorgio Lando (patroclo7) - Sunday, 23 March 2008, 21:51 GMT
Yes, with this glibc-2.7-9 wvdial works fine!

Loading...