Skip to content

Commit 6e522b6

Browse files
herbertHerbertKoelman
authored andcommitted
fixes #30 #31
- handle deprecation of auto_ptr.
1 parent bc206ca commit 6e522b6

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/thread.cpp

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,12 @@ namespace pthread {
123123

124124
thread_group::~thread_group(){
125125
while(! _threads.empty()){
126+
#if __cplusplus < 201103L
126127
std::auto_ptr<pthread::abstract_thread> pat(_threads.front());
128+
#else
129+
std::unique_ptr<pthread::abstract_thread> pat(_threads.front());
130+
#endif
131+
127132
_threads.pop_front();
128133

129134
if ( _destructor_joins_first ){

0 commit comments

Comments
 (0)