9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Irc segmentation fault
@ 2017-06-27 14:57 Rudolf Sykora
  2017-06-29  7:32 ` Rudolf Sykora
  0 siblings, 1 reply; 6+ messages in thread
From: Rudolf Sykora @ 2017-06-27 14:57 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

Hello,

I am trying to use the Irc acme client in plan9port, the one from

https://swtch.com/irc/

However, when I run it, it segfaults:

$ Irc irc.freenode.org
Segmentation fault

Has anybody used this client successfully?
(Or would you rather recommend something else?)

Thanks
Ruda



^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [9fans] Irc segmentation fault
  2017-06-27 14:57 [9fans] Irc segmentation fault Rudolf Sykora
@ 2017-06-29  7:32 ` Rudolf Sykora
  2017-06-29  7:39   ` Nick Owens
  0 siblings, 1 reply; 6+ messages in thread
From: Rudolf Sykora @ 2017-06-29  7:32 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

> $ Irc irc.freenode.org
> Segmentation fault

Do I have to use acid to debug it, or is it possible to use the usual
unix gdb to debug this on p9p?

Thanks
Ruda



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [9fans] Irc segmentation fault
  2017-06-29  7:32 ` Rudolf Sykora
@ 2017-06-29  7:39   ` Nick Owens
  2017-06-29  9:20     ` Rudolf Sykora
  0 siblings, 1 reply; 6+ messages in thread
From: Nick Owens @ 2017-06-29  7:39 UTC (permalink / raw)


acid is next to impossible to use on unix systems. just run gdb with
'thread apply all bt'.. should give you an idea of what's wrong.

On Jun 29, 2017 00:33, "Rudolf Sykora" <rudolf.sykora at gmail.com> wrote:

> > $ Irc irc.freenode.org
> > Segmentation fault
>
> Do I have to use acid to debug it, or is it possible to use the usual
> unix gdb to debug this on p9p?
>
> Thanks
> Ruda
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.9fans.net/private/9fans/attachments/20170629/19b3c16b/attachment.html>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [9fans] Irc segmentation fault
  2017-06-29  7:39   ` Nick Owens
@ 2017-06-29  9:20     ` Rudolf Sykora
       [not found]       ` <CAH_zEu663ZGshz1fFsVF4LrkJBGeNYGsR8bf4oXuFv4SKBdW-g@mail.gmail.com>
  0 siblings, 1 reply; 6+ messages in thread
From: Rudolf Sykora @ 2017-06-29  9:20 UTC (permalink / raw)


On 29 June 2017 at 09:39, Nick Owens <mischief at offblast.org> wrote:
> acid is next to impossible to use on unix systems. just run gdb with 'thread
> apply all bt'.. should give you an idea of what's wrong.

If I run Irc in gdb, I get

(gdb) run irc.freenode.org
Starting program: /usr/local/plan9port/bin/Irc irc.freenode.org
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff749bedf in raise () from /lib64/libpthread.so.0
(gdb) where
#0  0x00007ffff749bedf in raise () from /lib64/libpthread.so.0
#1  0x000000000040df34 in child () at daemonize.c:38
#2  0x000000000040e18e in _threadsetupdaemonize () at daemonize.c:153
#3  0x000000000040de3d in p9main (argc=2, argv=0x7fffffffdcb8) at thread.c:721
#4  0x0000000000402ae9 in main (argc=<optimized out>, argv=<optimized out>)
    at main.c:10

which I really don't understand...
How could argc, argv be 'optimized out'?

Thanks for any comments!
Ruda



^ permalink raw reply	[flat|nested] 6+ messages in thread

* [9fans] Irc segmentation fault
       [not found]       ` <CAH_zEu663ZGshz1fFsVF4LrkJBGeNYGsR8bf4oXuFv4SKBdW-g@mail.gmail.com>
@ 2017-06-29  9:29         ` Nick Owens
  2017-06-29  9:51           ` Rudolf Sykora
  0 siblings, 1 reply; 6+ messages in thread
From: Nick Owens @ 2017-06-29  9:29 UTC (permalink / raw)


you probably need to use gcc -O0 -g for that. but it looks like the problem
is in dameonize.c:38. lowering optimization might help since there might be
inlined functions.. haven't really looked at Irc.

On Jun 29, 2017 02:24, "Rudolf Sykora" <rudolf.sykora at gmail.com> wrote:

On 29 June 2017 at 09:39, Nick Owens <mischief at offblast.org> wrote:
> acid is next to impossible to use on unix systems. just run gdb with
'thread
> apply all bt'.. should give you an idea of what's wrong.

If I run Irc in gdb, I get

(gdb) run irc.freenode.org
Starting program: /usr/local/plan9port/bin/Irc irc.freenode.org
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib64/libthread_db.so.1".

Program received signal SIGSEGV, Segmentation fault.
0x00007ffff749bedf in raise () from /lib64/libpthread.so.0
(gdb) where
#0  0x00007ffff749bedf in raise () from /lib64/libpthread.so.0
#1  0x000000000040df34 in child () at daemonize.c:38
#2  0x000000000040e18e in _threadsetupdaemonize () at daemonize.c:153
#3  0x000000000040de3d in p9main (argc=2, argv=0x7fffffffdcb8) at
thread.c:721
#4  0x0000000000402ae9 in main (argc=<optimized out>, argv=<optimized out>)
    at main.c:10

which I really don't understand...
How could argc, argv be 'optimized out'?

Thanks for any comments!
Ruda
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.9fans.net/private/9fans/attachments/20170629/b99a304c/attachment-0001.html>


^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: [9fans] Irc segmentation fault
  2017-06-29  9:29         ` Nick Owens
@ 2017-06-29  9:51           ` Rudolf Sykora
  0 siblings, 0 replies; 6+ messages in thread
From: Rudolf Sykora @ 2017-06-29  9:51 UTC (permalink / raw)
  To: Fans of the OS Plan 9 from Bell Labs

On 29 June 2017 at 11:29, Nick Owens <mischief@offblast.org> wrote:
> you probably need to use gcc -O0 -g for that.

Doesn't it matter that the program is normally built with 9c?

Thanks
Ruda



^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2017-06-29  9:51 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2017-06-27 14:57 [9fans] Irc segmentation fault Rudolf Sykora
2017-06-29  7:32 ` Rudolf Sykora
2017-06-29  7:39   ` Nick Owens
2017-06-29  9:20     ` Rudolf Sykora
     [not found]       ` <CAH_zEu663ZGshz1fFsVF4LrkJBGeNYGsR8bf4oXuFv4SKBdW-g@mail.gmail.com>
2017-06-29  9:29         ` Nick Owens
2017-06-29  9:51           ` Rudolf Sykora

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).