mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-15 07:14:46 +02:00
use std::unique_ptr instead of std::auto_ptr with C++11+ compilers to prevent std::auto_ptr deprecation warnings
This commit is contained in:
@@ -89,7 +89,11 @@ public:
|
||||
|
||||
FastMutex::ScopedLock lock(_mutex);
|
||||
|
||||
#if __cplusplus < 201103L
|
||||
std::auto_ptr<AbstractFactory> ptr(pAbstractFactory);
|
||||
#else
|
||||
std::unique_ptr<AbstractFactory> ptr(pAbstractFactory);
|
||||
#endif
|
||||
typename FactoryMap::iterator it = _map.find(className);
|
||||
if (it == _map.end())
|
||||
_map[className] = ptr.release();
|
||||
|
Reference in New Issue
Block a user