Skip to content

Commit

Permalink
Update curl_exception.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
JosephP91 authored Sep 3, 2018
1 parent 8029199 commit c89b28d
Showing 1 changed file with 0 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/curl_exception.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,17 +22,13 @@ curl_exception::curl_exception(const std::string &error, const std::string &fun_

// Copy constructor implementation. It makes a copy of the traceback in a thread safe way.
curl_exception::curl_exception(const curl_exception &object) {
curl_exception::tracebackLocker.lock();
curl_exception::traceback = object.get_traceback();
curl_exception::tracebackLocker.unlock();
}

// Assignment operator implementation. Implement the assignment operation in a thread safe way avoiding self assignment.
curl_exception& curl_exception::operator=(curl_exception &object) {
if (&object != this) {
curl_exception::tracebackLocker.lock();
curl_exception::traceback = object.get_traceback();
curl_exception::tracebackLocker.unlock();
}
return *this;
}
Expand Down

0 comments on commit c89b28d

Please sign in to comment.