Menu

#4 std::uncaught_exception is not safe on IBM AIX/xlC

Unstable (example)
open
nobody
None
5
2014-08-18
2014-02-17
No

Hello

When using OTL on IBM AIX with the IBM xlC compiler version 11, we discovered that std::uncaught_exception() can return true if an exception is thrown in another thread. This means that OTL queries can silently fail to execute sometimes when exceptions are thrown in other unrelated parts of the program.

We found some limited information on this problem with std::uncaught_exception() and threads on the IBM DeveloperWorks website (including confirmation from IBM staff that this problem affects xlC on AIX but not on Linux; this refers to xlC version 9 but we have confirmed the problem also exists in version 11). See: https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

We propose the following change:

 // this becomes the default from version 4.0.162 and on.
 // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.
-#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))
+// also not enabled on IBM xlC for AIX (where the std::uncaught_exception 
+// flag is shared by all threads)
+#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(__xlC__)&&defined(_AIX))
 #define OTL_UNCAUGHT_EXCEPTION_ON
 #endif

Thanks!
Thomas

Related

Patches: #4

Discussion

  • Sergei Kuchin

    Sergei Kuchin - 2014-02-17

    There are other versions of xlC, like 10, 12, and there are different patch
    levels of each version of the compiler. Have you done any research on
    whether IBM has a fix for it, or at least what specific version + patch
    level of the compiler which has the problem? You may want to file a PMR
    with IBM. It's not a good idea to disable std::uncaught_exception() for all
    versions of xlC by default, which may break more code than it fixes.

    On Mon, Feb 17, 2014 at 5:07 AM, Thomas Munro tdmunro@users.sf.net wrote:


    Status: open
    Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
    Last Updated: Mon Feb 17, 2014 11:07 AM UTC
    Owner: nobody

    Hello

    When using OTL on IBM AIX with the IBM xlC compiler version 11, we
    discovered that std::uncaught_exception() can return true if an exception
    is thrown in another thread. This means that OTL queries can silently fail
    to execute sometimes when exceptions are thrown in other unrelated parts of
    the program.

    We found some limited information on this problem with
    std::uncaught_exception() and threads on the IBM DeveloperWorks website
    (including confirmation from IBM staff that this problem affects xlC on AIX
    but not on Linux; this refers to xlC version 9 but we have confirmed the
    problem also exists in version 11). See:
    https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

    We propose the following change:

    // this becomes the default from version 4.0.162 and on.
    // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.-#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))+// also not enabled on IBM xlC for AIX (where the std::uncaught_exception +// flag is shared by all threads)+#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
    #define OTL_UNCAUGHT_EXCEPTION_ON
    #endif

    Thanks!
    Thomas


    Sent from sourceforge.net because you indicated interest in
    https://sourceforge.net/p/otl/patches/4/

    To unsubscribe from further messages, please visit
    https://sourceforge.net/auth/subscriptions/

     

    Related

    Patches: #4

  • Thomas Munro

    Thomas Munro - 2014-02-17

    Ok, I can reproduce the problem with the following two compilers (this is the output from -qversion):

    IBM XL C/C++ for AIX, V12.1 (5765-J02, 5725-C72)
    Version: 12.01.0000.0007
    
    IBM XL C/C++ for AIX, V11.1 (5724-X13)
    Version: 11.01.0000.0010
    

    The first one seems to be the current latest level/patch. I don't have access to anything older. I guess it must be changing in the forthcoming C++11 compiler, since C++11 explicitly specifies that std::uncaught_exception() refers to the current thread, but I don't see how we could anticipate which future version numbers will be multithreaded. Do you think there is any point in including a check that only disables the macro if defined(_AIX) && (__IBMCPP__<=1201)? Wouldn't it make more sense to leave it disabled for all AIX/xLC platforms until we get a positive sighting of one that works?

    We haven't filed a PMR. I will ask about that.

    FWIW here is the test program I used:

    // Code from https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233
    // Modified to use Pthread instead of Boost threads, and mildly reformatted.
    
    #include <cassert>
    #include <iostream>
    #include <stdexcept>
    
    #include <unistd.h>
    #include <pthread.h>
    
    struct DelayedDestruction {
        ~DelayedDestruction() {
            sleep(4);
        }
    };
    
    extern "C"
    void *thread1(void *)
    {
    
        try {
            sleep(3);
            DelayedDestruction d;      
            throw 1;
        } catch(...) {
        }
        return 0;
    }
    
    extern "C"
    void *thread2(void *)
    {
        for (int i = 0; i != 10; ++i) {
            if (std::uncaught_exception()) {
                std::cout << "Oops: uncaught exception detected in thread2()\n";
            } else {
                std::cout << "All well in thread2()\n";
            }
            sleep(1);
        }
        return 0;
    }
    
    int main()
    {
        pthread_t t1;
        pthread_t t2;
        assert(pthread_create(&t1, 0, &thread1, 0) == 0);
        assert(pthread_create(&t2, 0, &thread2, 0) == 0);
        assert(pthread_join(t1, 0) == 0);
        assert(pthread_join(t2, 0) == 0);
        return 0;
    }
    
     
    • Sergei Kuchin

      Sergei Kuchin - 2014-02-17

      I'll add #define OTL_UNCAUGHT_EXCEPTION_OFF for you to be able to turn the
      feature off. That makes more sense. Check for updates on the OTL Web site.

      On Mon, Feb 17, 2014 at 9:09 AM, Thomas Munro tdmunro@users.sf.net wrote:

      Ok, I can reproduce the problem with the following two compilers (this is
      the output from -qversion):

      IBM XL C/C++ for AIX, V12.1 (5765-J02, 5725-C72)Version: 12.01.0000.0007
      IBM XL C/C++ for AIX, V11.1 (5724-X13)Version: 11.01.0000.0010

      The first one seems to be the current latest level/patch. I don't have
      access to anything older. I guess it must be changing in the forthcoming
      C++11 compiler, since C++11 explicitly specifies that
      std::uncaught_exception() refers to the current thread, but I don't see
      how we could anticipate which future version numbers will be multithreaded.
      Do you think there is any point in including a check that only disables the
      macro if defined(_AIX) && (IBMCPP<=1201)? Wouldn't it make more sense
      to leave it disabled for all AIX/xLC platforms until we get a positive
      sighting of one that works?

      We haven't filed a PMR. I will ask about that.

      FWIW here is the test program I used:

      // Code from https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233// Modified to use Pthread instead of Boost threads, and mildly reformatted.

      include <cassert>#include <iostream>#include <stdexcept>

      include <unistd.h>#include <pthread.h>

      struct DelayedDestruction {
      ~DelayedDestruction() {
      sleep(4);
      }};
      extern "C"void thread1(void ){

      try {
          sleep(3);
          DelayedDestruction d;
          throw 1;
      } catch(...) {
      }
      return 0;}
      

      extern "C"void thread2(void ){
      for (int i = 0; i != 10; ++i) {
      if (std::uncaught_exception()) {
      std::cout << "Oops: uncaught exception detected in thread2()\n";
      } else {
      std::cout << "All well in thread2()\n";
      }
      sleep(1);
      }
      return 0;}
      int main(){
      pthread_t t1;
      pthread_t t2;
      assert(pthread_create(&t1, 0, &thread1, 0) == 0);
      assert(pthread_create(&t2, 0, &thread2, 0) == 0);
      assert(pthread_join(t1, 0) == 0);
      assert(pthread_join(t2, 0) == 0);
      return 0;}


      Status: open
      Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
      Last Updated: Mon Feb 17, 2014 11:07 AM UTC
      Owner: nobody

      Hello

      When using OTL on IBM AIX with the IBM xlC compiler version 11, we
      discovered that std::uncaught_exception() can return true if an exception
      is thrown in another thread. This means that OTL queries can silently fail
      to execute sometimes when exceptions are thrown in other unrelated parts of
      the program.

      We found some limited information on this problem with
      std::uncaught_exception() and threads on the IBM DeveloperWorks website
      (including confirmation from IBM staff that this problem affects xlC on AIX
      but not on Linux; this refers to xlC version 9 but we have confirmed the
      problem also exists in version 11). See:
      https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

      We propose the following change:

      // this becomes the default from version 4.0.162 and on.
      // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.-#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))+// also not enabled on IBM xlC for AIX (where the std::uncaught_exception +// flag is shared by all threads)+#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
      #define OTL_UNCAUGHT_EXCEPTION_ON
      #endif

      Thanks!
      Thomas


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/otl/patches/4/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Patches: #4

      • Sergei Kuchin

        Sergei Kuchin - 2014-02-19

        Thomas,

        Was the problem in 32-bit or 64-bit mode?

        Thanks,
        Sergei
        Sergei Kuchin wrote:

        I'll add #define OTL_UNCAUGHT_EXCEPTION_OFF for you to be able to turn the
        feature off. That makes more sense. Check for updates on the OTL Web site.

        On Mon, Feb 17, 2014 at 9:09 AM, Thomas Munro tdmunro@users.sf.net
        tdmunro@users.sf.net wrote:

        Ok, I can reproduce the problem with the following two compilers
        (this is
        the output from -qversion):
        
        IBM XL C/C++ for AIX, V12.1 (5765-J02, 5725-C72)Version:
        12.01.0000.0007
        IBM XL C/C++ for AIX, V11.1 (5724-X13)Version: 11.01.0000.0010
        
        The first one seems to be the current latest level/patch. I don't have
        access to anything older. I guess it must be changing in the
        forthcoming
        C++11 compiler, since C++11 explicitly specifies that
        std::uncaught_exception() refers to the current thread, but I
        don't see
        how we could anticipate which future version numbers will be
        multithreaded.
        Do you think there is any point in including a check that only
        disables the
        macro if defined(_AIX) && (*IBMCPP*<=1201)? Wouldn't it make more
        sense
        to leave it disabled for all AIX/xLC platforms until we get a positive
        sighting of one that works?
        
        We haven't filed a PMR. I will ask about that.
        
        FWIW here is the test program I used:
        
        // Code from
        https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233//
        Modified to use Pthread instead of Boost threads, and mildly
        reformatted.
        
          include #include #include
        
          include #include
        
        struct DelayedDestruction {
        ~DelayedDestruction() {
        sleep(4);
        }};
        extern "C"void /thread1(void /){
        
        try  {
             sleep(3);
             DelayedDestruction  d;
             throw  1;
        }  catch(...)  {
        }
        return  0;}
        
        extern "C"void /thread2(void /){
        for (int i = 0; i != 10; ++i) {
        if (std::uncaught_exception()) {
        std::cout << "Oops: uncaught exception detected in thread2()\n";
        } else {
        std::cout << "All well in thread2()\n";
        }
        sleep(1);
        }
        return 0;}
        int main(){
        pthread_t t1;
        pthread_t t2;
        assert(pthread_create(&t1, 0, &thread1, 0) == 0);
        assert(pthread_create(&t2, 0, &thread2, 0) == 0);
        assert(pthread_join(t1, 0) == 0);
        assert(pthread_join(t2, 0) == 0);
        return 0;}
        
        ------------------------------------------------------------------------
        
          * [patches:#4] http://sourceforge.net/p/otl/patches/4/
            std::uncaught_exception is not safe on IBM AIX/xlC*
        
        /Status:/ open
        /Created:/ Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
        /Last Updated:/ Mon Feb 17, 2014 11:07 AM UTC
        /Owner:/ nobody
        
        Hello
        
        When using OTL on IBM AIX with the IBM xlC compiler version 11, we
        discovered that std::uncaught_exception() can return true if an
        exception
        is thrown in another thread. This means that OTL queries can
        silently fail
        to execute sometimes when exceptions are thrown in other unrelated
        parts of
        the program.
        
        We found some limited information on this problem with
        std::uncaught_exception() and threads on the IBM DeveloperWorks
        website
        (including confirmation from IBM staff that this problem affects
        xlC on AIX
        but not on Linux; this refers to xlC version 9 but we have
        confirmed the
        problem also exists in version 11). See:
        https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233
        
        We propose the following change:
        
        // this becomes the default from version 4.0.162 and on.
        // the #define is not enabled for vc++ 6.0 in version 4.0.167 and
        higher.-#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) &&
        !(defined(_MSC_VER)&&(_MSC_VER==1200))+// also not enabled on IBM
        xlC for AIX (where the std::uncaught_exception +// flag is shared
        by all threads)+#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) &&
        !(defined(_MSC_VER)&&(_MSC_VER==1200)) &&
        !(defined(*xlC*)&&defined(_AIX))
        #define OTL_UNCAUGHT_EXCEPTION_ON
        #endif
        
        Thanks!
        Thomas
        
        ------------------------------------------------------------------------
        
        Sent from sourceforge.net because you indicated interest in
        https://sourceforge.net/p/otl/patches/4/
        
        To unsubscribe from further messages, please visit
        https://sourceforge.net/auth/subscriptions/
        

        [patches:#4] std::uncaught_exception is not safe on IBM AIX/xlC

        Status: open
        Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
        Last Updated: Mon Feb 17, 2014 03:09 PM UTC
        Owner: nobody

        Hello

        When using OTL on IBM AIX with the IBM xlC compiler version 11, we
        discovered that |std::uncaught_exception()| can return true if an
        exception is thrown in another thread. This means that OTL queries can
        silently fail to execute sometimes when exceptions are thrown in other
        unrelated parts of the program.

        We found some limited information on this problem with
        |std::uncaught_exception()| and threads on the IBM DeveloperWorks
        website (including confirmation from IBM staff that this problem
        affects xlC on AIX but not on Linux; this refers to xlC version 9 but
        we have confirmed the problem also exists in version 11). See:
        https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

        We propose the following change:

        // this becomes the default from version 4.0.162 and on.
        // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.
        -#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))
        +// also not enabled on IBM xlC for AIX (where the std::uncaught_exception
        +// flag is shared by all threads)
        +#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
        #define OTL_UNCAUGHT_EXCEPTION_ON
        #endif

        Thanks!
        Thomas


        Sent from sourceforge.net because you indicated interest in
        https://sourceforge.net/p/otl/patches/4/

        To unsubscribe from further messages, please visit
        https://sourceforge.net/auth/subscriptions/

         

        Related

        Patches: #4

  • Thomas Munro

    Thomas Munro - 2014-02-20

    Both (just tested the above program with -q32 and -q64 in xlC 12.1).

     
    • Sergei Kuchin

      Sergei Kuchin - 2014-02-20

      Thanks for the info.

      On Thu, Feb 20, 2014 at 5:54 AM, Thomas Munro tdmunro@users.sf.net wrote:

      Both (just tested the above program with -q32 and -q64 in xlC 12.1).

      Status: open
      Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
      Last Updated: Mon Feb 17, 2014 03:09 PM UTC
      Owner: nobody

      Hello

      When using OTL on IBM AIX with the IBM xlC compiler version 11, we
      discovered that std::uncaught_exception() can return true if an exception
      is thrown in another thread. This means that OTL queries can silently fail
      to execute sometimes when exceptions are thrown in other unrelated parts of
      the program.

      We found some limited information on this problem with
      std::uncaught_exception() and threads on the IBM DeveloperWorks website
      (including confirmation from IBM staff that this problem affects xlC on AIX
      but not on Linux; this refers to xlC version 9 but we have confirmed the
      problem also exists in version 11). See:
      https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

      We propose the following change:

      // this becomes the default from version 4.0.162 and on.
      // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.-#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))+// also not enabled on IBM xlC for AIX (where the std::uncaught_exception +// flag is shared by all threads)+#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
      #define OTL_UNCAUGHT_EXCEPTION_ON
      #endif

      Thanks!
      Thomas


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/otl/patches/4/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Patches: #4

    • Sergei Kuchin

      Sergei Kuchin - 2014-02-22

      Thomas,

      I checked with the latest patch level of xlC 10, your test program shows
      the same problem. It looks that IBM either doesn't give a shit about
      "small problems", or they've not been aware of the problem all along.
      That's a big gaping hole in their C++ runtime! Thanks for the info.

      Sergei

      Thomas Munro wrote:

      Both (just tested the above program with |-q32| and |-q64| in xlC 12.1).


      [patches:#4] http://sourceforge.net/p/otl/patches/4/
      std::uncaught_exception is not safe on IBM AIX/xlC

      Status: open
      Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
      Last Updated: Mon Feb 17, 2014 03:09 PM UTC
      Owner: nobody

      Hello

      When using OTL on IBM AIX with the IBM xlC compiler version 11, we
      discovered that |std::uncaught_exception()| can return true if an
      exception is thrown in another thread. This means that OTL queries can
      silently fail to execute sometimes when exceptions are thrown in other
      unrelated parts of the program.

      We found some limited information on this problem with
      |std::uncaught_exception()| and threads on the IBM DeveloperWorks
      website (including confirmation from IBM staff that this problem
      affects xlC on AIX but not on Linux; this refers to xlC version 9 but
      we have confirmed the problem also exists in version 11). See:
      https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

      We propose the following change:

      // this becomes the default from version 4.0.162 and on.
      // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.
      -#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))
      +// also not enabled on IBM xlC for AIX (where the std::uncaught_exception
      +// flag is shared by all threads)
      +#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
      #define OTL_UNCAUGHT_EXCEPTION_ON
      #endif

      Thanks!
      Thomas


      Sent from sourceforge.net because you indicated interest in
      https://sourceforge.net/p/otl/patches/4/

      To unsubscribe from further messages, please visit
      https://sourceforge.net/auth/subscriptions/

       

      Related

      Patches: #4

      • Thomas Munro

        Thomas Munro - 2014-02-22

        Yeah, it's really not great. At a guess, they may be conservative about preserving ABI compatibility between runtime library versions, and not want to change it.

        We have OTL_DESTRUCTORS_DO_NOT_THROW defined, so it looks like there is no way that exceptions can be thrown out of destructors causing std::terminate() anyway. So what could go wrong if we disable the std::uncaught_exception() early returns, I mean, don't these two techniques both solve the same problem?

        FWIW, I noticed that Herb Sutter recommends not using std::uncaught_exception() in http://www.gotw.ca/gotw/047.htm .

         
        • Sergei Kuchin

          Sergei Kuchin - 2014-02-22

          Robert,

          RIIA idiom is not complete: it recommends closing resources when objects
          go out of scope (a.k.a. destructors). Also, it is recommended in general
          to use exceptions to communicate exceptional conditions / errors. When a
          destructor throws, and the exception is not caught, the program aborts.
          So, it not clear how to reconcile the contradiction between the
          recommendations, and the implementation. Hence,
          std::uncaught_exception() is needed, but not recommended. There is
          another good example in C++ of such contradiction: const member
          functions / methods in a class, and "mutable" data members to hide the
          fact of object mutability in a const method. Besides the fluke in
          std::uncaught_exception() in xlC, every other C++ compiler that OTL has
          been used with doesn't seem to have that type of a problem (at least,
          nobody else complained about that specific problem so far).

          Here's a link to an article on the other side of the argument about
          throwing destructors: http://www.kolpackov.net/projects/c++/eh/dtor-1.xhtml

          Cheers,
          Sergei

          Thomas Munro wrote:

          Yeah, it's really not great. At a guess, they may be conservative
          about preserving ABI compatibility between runtime library versions,
          and not want to change it.

          We have |OTL_DESTRUCTORS_DO_NOT_THROW| defined, so it looks like there
          is no way that exceptions can be thrown out of destructors causing
          |std::terminate()| anyway. So what could go wrong if we disable the
          |std::uncaught_exception()| early returns, I mean, don't these two
          techniques both solve the same problem?

          FWIW, I noticed that Herb Sutter recommends not using
          |std::uncaught_exception()| in http://www.gotw.ca/gotw/047.htm .


          [patches:#4] http://sourceforge.net/p/otl/patches/4/
          std::uncaught_exception is not safe on IBM AIX/xlC

          Status: open
          Created: Mon Feb 17, 2014 11:07 AM UTC by Thomas Munro
          Last Updated: Thu Feb 20, 2014 11:54 AM UTC
          Owner: nobody

          Hello

          When using OTL on IBM AIX with the IBM xlC compiler version 11, we
          discovered that |std::uncaught_exception()| can return true if an
          exception is thrown in another thread. This means that OTL queries can
          silently fail to execute sometimes when exceptions are thrown in other
          unrelated parts of the program.

          We found some limited information on this problem with
          |std::uncaught_exception()| and threads on the IBM DeveloperWorks
          website (including confirmation from IBM staff that this problem
          affects xlC on AIX but not on Linux; this refers to xlC version 9 but
          we have confirmed the problem also exists in version 11). See:
          https://www.ibm.com/developerworks/community/forums/html/topic?id=77777777-0000-0000-0000-000014531233

          We propose the following change:

          // this becomes the default from version 4.0.162 and on.
          // the #define is not enabled for vc++ 6.0 in version 4.0.167 and higher.
          -#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200))
          +// also not enabled on IBM xlC for AIX (where the std::uncaught_exception
          +// flag is shared by all threads)
          +#if !defined(OTL_UNCAUGHT_EXCEPTION_ON) && !(defined(_MSC_VER)&&(_MSC_VER==1200)) && !(defined(xlC)&&defined(_AIX))
          #define OTL_UNCAUGHT_EXCEPTION_ON
          #endif

          Thanks!
          Thomas


          Sent from sourceforge.net because you indicated interest in
          https://sourceforge.net/p/otl/patches/4/

          To unsubscribe from further messages, please visit
          https://sourceforge.net/auth/subscriptions/

           

          Related

          Patches: #4


Log in to post a comment.