aMule Forum

Please login or register.

Login with username, password and session length
Advanced search  

News:

We're back! (IN POG FORM)

Author Topic: program error in Ubuntu  (Read 2745 times)

jankins

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 8
program error in Ubuntu
« on: September 10, 2009, 10:40:29 AM »

Dear All,

I am a new learner.

I have downloaded aMule-2.2.5 source code and changed a little bit in Visual Studio 2008 and it works well.  But when move them to Ubuntu-8.04 and compile it and run. The program is crashed without showing any information.

I use "KDbg" to trace it. Then I see the lines in Stack:

__kernel_vsyscall()
raise() from /lib/tls/i686/cmov/libc.so.6
abort() from /lib/tls/i686/cmov/libc.so.6
wsFataSignalHandler() from /usr/lib/libwx_baseu-2.8.so.0
<signal handler called>
Kademlia::CRoutingZone::AddUnfiltered(this=........
......


Also, I use "gdb" to debug it. And I get the information:

Program received signal SIGILL, Illegal instruction.
[Switching to Thread 0xb69d3b40 (LWP 8292)]
0x08256e4a in Kademlia::CRoutingZone::AddUnfiltered (this=0x8c014a8,
    id=@0xbf9c80f4, ip=1146853884, port=4672, tport=4662, version=0 '\0',
    key=@0xbf9c8104, ipVerified=@0xbf9c815c, update=false, fromNodesDat=true,
    fromHello=false) at kademlia/routing/RoutingZone.cpp:398
398         if (Add(contact, update, ipVerified)) {
(gdb) n
0xb764bc50 in wxFatalSignalHandler () from /usr/lib/libwx_baseu-2.8.so.0
Current language:  auto; currently asm
(gdb) n
Single stepping until exit from function wxFatalSignalHandler,
which has no line number information.

I installed the "wxGTK-2.8.10".

Thanks so much.

Jankins


« Last Edit: September 10, 2009, 10:47:17 AM by jankins »
Logged

jankins

  • Approved Newbie
  • *
  • Karma: 0
  • Offline Offline
  • Posts: 8
Re: program error in Ubuntu
« Reply #1 on: September 10, 2009, 12:15:38 PM »

My bad.

I finally find out the reason.

I tried to print out the "wxString" with format "%s", which cause the program crashes.

But, it's kind of weird that this error didn't show up in Windows.

Thanks.
Logged

Stu Redman

  • Administrator
  • Hero Member
  • *****
  • Karma: 214
  • Offline Offline
  • Posts: 3739
  • Engines screaming
Re: program error in Ubuntu
« Reply #2 on: September 10, 2009, 10:52:11 PM »

What happens then is pretty random, and may crash or not. I'm sure it didn't work on Windows.
Logged
The image of mother goddess, lying dormant in the eyes of the dead, the sheaf of the corn is broken, end the harvest, throw the dead on the pyre -- Iron Maiden, Isle of Avalon