setjmp/longjmp in Symbian OS

Discussion in 'C++' started by alexey_m, Sep 29, 2005.

  1. alexey_m

    alexey_m Guest

    Hi!
    I try to use setjmp/longjmp instructions, but application fails with
    KERN-EXEC 3. Code is very simple:
    int Main()
    {
    jmp_buf jump_buffer;
    if ( setjmp( jump_buffer ) == 0 )
    {
    longjmp( jump_buffer, 1 );
    }
    return 0;
    }

    Anybody used setjmp/longjmp (in Symbian)? Share experience, please.
    Thanks.
    alexey_m, Sep 29, 2005
    #1
    1. Advertising

  2. alexey_m

    mlimber Guest

    alexey_m wrote:
    > Hi!
    > I try to use setjmp/longjmp instructions, but application fails with
    > KERN-EXEC 3. Code is very simple:
    > int Main()
    > {
    > jmp_buf jump_buffer;
    > if ( setjmp( jump_buffer ) == 0 )
    > {
    > longjmp( jump_buffer, 1 );
    > }
    > return 0;
    > }
    >
    > Anybody used setjmp/longjmp (in Symbian)? Share experience, please.
    > Thanks.


    The functions setjmp and longjmp are for C-style stack unwinding and
    are discouraged in C++ because they are incompatible with exception
    handling (TC++PL, 16.1.2). I'd suggest you post this either in
    comp.lang.c or in a newsgroup related to Symbian.

    Cheers! --M
    mlimber, Sep 29, 2005
    #2
    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. Thomas Baruchel

    How dirty is setjmp+fopen+longjmp ?

    Thomas Baruchel, Oct 2, 2003, in forum: C Programming
    Replies:
    2
    Views:
    447
    Eric Sosman
    Oct 2, 2003
  2. Mantorok Redgormor

    setjmp, longjmp

    Mantorok Redgormor, Nov 12, 2003, in forum: C Programming
    Replies:
    2
    Views:
    418
    Ian Woods
    Nov 12, 2003
  3. someone
    Replies:
    5
    Views:
    3,436
    SM Ryan
    May 1, 2004
  4. Michael B Allen

    Is setjmp/longjmp ok?

    Michael B Allen, May 1, 2004, in forum: C Programming
    Replies:
    11
    Views:
    2,240
    -wombat-
    May 4, 2004
  5. Ravi Uday

    setjmp/longjmp

    Ravi Uday, Aug 3, 2004, in forum: C Programming
    Replies:
    2
    Views:
    536
    Dave Vandervies
    Aug 6, 2004
Loading...

Share This Page