Seg Fault in C library.

Discussion in 'C++' started by Jun, Dec 17, 2007.

  1. Jun

    Jun Guest

    I'm running on 2.2 Kernel on a PPC platform and getting an intermttent
    seg
    fault on one of my threads. I have a spin loop after it detected the
    seg fault and after I loaded GDB and did a trace, I get the following
    stack trace below. It does not go further down where in application
    code the C library was called. Has anyone encountered this issue? How
    does on get to try to isolate this issue. I appreciate any response
    on this.

    bt 12
    #0 0x014ff400 in nanosleep () from /lib/libc.so.6
    #1 0x014ff384 in sleep () from /lib/libc.so.6
    #2 0x018290c8 in signal_handler (num=11, inf=0x7e1ff4b0,
    ctx=0x1b22228)
    at cabd.cpp:252
    #3 0x016f9808 in pthread_kill () from /lib/libpthread.so.0
    #4 <signal handler called>
    #5 0x014b768c in _IO_flush_all_linebuffered () from /lib/libc.so.6
    #6 0x0159ce20 in ?? () from /lib/libc.so.6
    (gdb)
    Jun, Dec 17, 2007
    #1
    1. Advertising

  2. Jun wrote:
    > I'm running on 2.2 Kernel on a PPC platform and getting an intermttent
    > seg
    > fault on one of my threads. I have a spin loop after it detected the
    > seg fault and after I loaded GDB and did a trace, I get the following
    > stack trace below. It does not go further down where in application
    > code the C library was called. Has anyone encountered this issue? How
    > does on get to try to isolate this issue. I appreciate any response
    > on this.
    >
    > bt 12
    > #0 0x014ff400 in nanosleep () from /lib/libc.so.6
    > #1 0x014ff384 in sleep () from /lib/libc.so.6
    > #2 0x018290c8 in signal_handler (num=11, inf=0x7e1ff4b0,
    > ctx=0x1b22228)
    > at cabd.cpp:252
    > #3 0x016f9808 in pthread_kill () from /lib/libpthread.so.0
    > #4 <signal handler called>
    > #5 0x014b768c in _IO_flush_all_linebuffered () from /lib/libc.so.6
    > #6 0x0159ce20 in ?? () from /lib/libc.so.6
    > (gdb)


    I am sorry, I was trying to find a C++ langauge issue here, but failed.

    Could you perhaps elaborate a bit why do you think it's a problem that
    can be solved by means of C++ language? Consider that there are forums
    'comp.os.linux.*' out there (I am guessing from the mention of 2.2 and
    the overall bluntness of the post), and that there is 'comp.lang.c' out
    there too, and there is a whole bunch of 'gnu.*' newsgroups as well.

    In other words, what makes you think that 'c.l.c++' is the right place
    to post this?

    V
    --
    Please remove capital 'A's when replying by e-mail
    I do not respond to top-posted replies, please don't ask
    Victor Bazarov, Dec 17, 2007
    #2
    1. Advertising

  3. Jun

    Jun Guest

    On Dec 17, 11:44 am, "Victor Bazarov" <> wrote:
    > Jun wrote:
    > > I'm running on 2.2 Kernel on a PPC platform and getting an intermttent
    > > seg
    > > fault on one of my threads. I have a spin loop after it detected the
    > > seg fault and after I loaded GDB and did a trace, I get the following
    > > stack trace below. It does not go further down where in application
    > > code the C library was called. Has anyone encountered this issue? How
    > > does on get to try to isolate this issue. I appreciate any response
    > > on this.

    >
    > > bt 12
    > > #0 0x014ff400 in nanosleep () from /lib/libc.so.6
    > > #1 0x014ff384 in sleep () from /lib/libc.so.6
    > > #2 0x018290c8 in signal_handler (num=11, inf=0x7e1ff4b0,
    > > ctx=0x1b22228)
    > > at cabd.cpp:252
    > > #3 0x016f9808 in pthread_kill () from /lib/libpthread.so.0
    > > #4 <signal handler called>
    > > #5 0x014b768c in _IO_flush_all_linebuffered () from /lib/libc.so.6
    > > #6 0x0159ce20 in ?? () from /lib/libc.so.6
    > > (gdb)

    >
    > I am sorry, I was trying to find a C++ langauge issue here, but failed.
    >
    > Could you perhaps elaborate a bit why do you think it's a problem that
    > can be solved by means of C++ language? Consider that there are forums
    > 'comp.os.linux.*' out there (I am guessing from the mention of 2.2 and
    > the overall bluntness of the post), and that there is 'comp.lang.c' out
    > there too, and there is a whole bunch of 'gnu.*' newsgroups as well.
    >
    > In other words, what makes you think that 'c.l.c++' is the right place
    > to post this?
    >
    > V
    > --
    > Please remove capital 'A's when replying by e-mail
    > I do not respond to top-posted replies, please don't ask- Hide quoted text -
    >
    > - Show quoted text -


    You're right, I should post this in the C or the linux gruops. Thanks.
    Jun, Dec 17, 2007
    #3
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Vinod

    Suprising seg fault!!!

    Vinod, Sep 27, 2003, in forum: C++
    Replies:
    3
    Views:
    465
    Ron Natalie
    Sep 27, 2003
  2. Corrine
    Replies:
    1
    Views:
    421
    Gianni Mariani
    Nov 27, 2003
  3. Manuel Maria Diaz Gomez

    fstream::open & seg fault

    Manuel Maria Diaz Gomez, Jul 20, 2004, in forum: C++
    Replies:
    3
    Views:
    1,193
    John Harrison
    Jul 20, 2004
  4. goktan
    Replies:
    4
    Views:
    2,022
    Howard
    Aug 2, 2004
  5. Matthias Kaeppler

    seg-fault on vector-auto-reserve

    Matthias Kaeppler, Feb 27, 2005, in forum: C++
    Replies:
    2
    Views:
    464
    Victor Bazarov
    Feb 27, 2005
Loading...

Share This Page