Qpid
  1. Qpid
  2. QPID-4855

[AMQP 1.0] compilation error on older compilers

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 0.22
    • Fix Version/s: 0.22
    • Component/s: C++ Client
    • Labels:
      None

      Description

      E.g. Description of problem:
      [ 41%] Building CXX object src/CMakeFiles/amqpc.dir/qpid/messaging/amqp/ConnectionHandle.o
      cd /builddir/build/BUILD/qpid-0.22/cpp/src && /usr/bin/c++ -Damqpc_EXPORTS -DHAVE_CONFIG_H -fvisibility-inlines-hidden -Werror -pedantic -Wall -Wextra -Wno-shadow -Wpointer-arith -Wcast-qual -Wcast-align -Wno-long-long -Wvolatile-register-var -Winvalid-pch -Wno-system-headers -Woverloaded-virtual -O2 -g -fPIC -I/builddir/build/BUILD/qpid-0.22/cpp/src -I/builddir/build/BUILD/qpid-0.22/cpp/src/../include -pthread -I/usr/usr/include -o CMakeFiles/amqpc.dir/qpid/messaging/amqp/ConnectionHandle.o -c /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/ConnectionHandle.cpp
      cc1plus: warnings being treated as errors
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory: In destructor 'std::auto_ptr<_Tp>::~auto_ptr() [with _Tp = qpid::Sasl]':
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/Sasl.h:42: instantiated from 'std::auto_ptr<_Tp>::~auto_ptr() [with _Tp = qpid::messaging::amqp::Sasl]'
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/ConnectionContext.cpp:58: instantiated from here
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: warning: possible problem detected in invocation of delete operator:
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: warning: invalid use of undefined type 'struct qpid::Sasl'
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/Sasl.h:29: warning: forward declaration of 'struct qpid::Sasl'
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: note: neither the destructor nor the class-specific operator delete will be called, even if they are declared when the class is defined.
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory: In destructor 'std::auto_ptr<_Tp>::~auto_ptr() [with _Tp = qpid::sys::SecurityLayer]':
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/Sasl.h:42: instantiated from 'std::auto_ptr<_Tp>::~auto_ptr() [with _Tp = qpid::messaging::amqp::Sasl]'
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/ConnectionContext.cpp:58: instantiated from here
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: warning: possible problem detected in invocation of delete operator:
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: warning: invalid use of undefined type 'struct qpid::sys::SecurityLayer'
      /builddir/build/BUILD/qpid-0.22/cpp/src/qpid/messaging/amqp/Sasl.h:31: warning: forward declaration of 'struct qpid::sys::SecurityLayer'
      /usr/lib/gcc/x86_64-redhat-linux/4.1.2/../../../../include/c++/4.1.2/memory:259: note: neither the destructor nor the class-specific operator delete will be called, even if they are declared when the class is defined.
      make[2]: *** [src/CMakeFiles/amqpc.dir/qpid/messaging/amqp/ConnectionContext.o] Error 1
      make[2]: *** Waiting for unfinished jobs....

        Activity

        Gordon Sim created issue -
        Show
        Gordon Sim added a comment - Fixed by http://svn.apache.org/viewvc?view=revision&revision=1483436
        Gordon Sim made changes -
        Field Original Value New Value
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Hide
        Justin Ross added a comment -

        I asked Gordon to merge this to the 0.22 branch. The change is minimal, and it fixes a build failure on rhel 5, still in wide use. Approved for 0.22.

        Show
        Justin Ross added a comment - I asked Gordon to merge this to the 0.22 branch. The change is minimal, and it fixes a build failure on rhel 5, still in wide use. Approved for 0.22.
        Show
        Gordon Sim added a comment - Merged to 0.22: http://svn.apache.org/viewvc?view=revision&revision=1486009
        Gordon Sim made changes -
        Fix Version/s 0.22 [ 12324272 ]
        Fix Version/s 0.23 [ 12324273 ]
        Justin Ross made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Gordon Sim
            Reporter:
            Gordon Sim
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development