From bf0b97d48c4b17e5dc96ddfa0eabd4c2c9a74b21 Mon Sep 17 00:00:00 2001 From: Giuseppe Date: Sat, 22 Apr 2017 09:55:16 +0200 Subject: [PATCH] Update curl_exception.h Now traceback vector is completely thread safe. --- include/curl_exception.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/include/curl_exception.h b/include/curl_exception.h index bc01b89..add0ce6 100644 --- a/include/curl_exception.h +++ b/include/curl_exception.h @@ -88,9 +88,11 @@ namespace curl { // Implementation of print_traceback inline void curl_exception::print_traceback() const { + curl_exception::tracebackLocker.lock(); std::for_each(curl_exception::traceback.begin(),curl_exception::traceback.end(),[](const curlcpp_traceback_object &value) { std::cout<<"ERROR: "<