ecap_clamav_adapter uses tr1::static_pointer_cast

Bug #1595562 reported by Patrick Welche
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
eCAP
New
Undecided
Unassigned

Bug Description

https://bugs.launchpad.net/ecap/+bug/1595488

explains why a move to C++11 in squid's footsteps seems necessary.

Code like:

      const libecap::shared_ptr<Service> s =
                    std::tr1::static_pointer_cast<Service>(self);

in ecap_clamav_adapter's src/Service.cc shows that the libecap::shared_ptr dance in libecap's memory.h, while a good idea, would end up breaking in practice.

Revision history for this message
Patrick Welche (prlw1) wrote :

Update to C++11

As per https://bugs.launchpad.net/ecap/+bug/1595488 it seems that
moving to requiring C++11 in line with squid is necessary.

- Enforce C++11 requirement using autoconf-archive macros.
- Remove trace of std::tr1.
- Replace deprecated auto_ptr with unique_ptr.
- As you already depend on pkg-config to find libecap, do
  the same for libclamav. (If you prefer, I could go the other
  way and replace pkg-config with real autoconf detection for
  libecap.)
- add ax_pthread.m4 to fix missing macros.

Revision history for this message
Patrick Welche (prlw1) wrote :

Stop using libecap/common/memory.h and std::shared_ptr and friends directly.

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.