You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@thrift.apache.org by br...@apache.org on 2011/09/01 18:52:57 UTC
svn commit: r1164164 - /thrift/trunk/lib/cpp/src/concurrency/Mutex.h
Author: bryanduxbury
Date: Thu Sep 1 16:52:56 2011
New Revision: 1164164
URL: http://svn.apache.org/viewvc?rev=1164164&view=rev
Log:
THRIFT-1317. cpp: Remove copy constructibility from
thrift::concurrency::Guard
Patch: Jordan DeLong
Modified:
thrift/trunk/lib/cpp/src/concurrency/Mutex.h
Modified: thrift/trunk/lib/cpp/src/concurrency/Mutex.h
URL: http://svn.apache.org/viewvc/thrift/trunk/lib/cpp/src/concurrency/Mutex.h?rev=1164164&r1=1164163&r2=1164164&view=diff
==============================================================================
--- thrift/trunk/lib/cpp/src/concurrency/Mutex.h (original)
+++ thrift/trunk/lib/cpp/src/concurrency/Mutex.h Thu Sep 1 16:52:56 2011
@@ -21,6 +21,7 @@
#define _THRIFT_CONCURRENCY_MUTEX_H_ 1
#include <boost/shared_ptr.hpp>
+#include <boost/noncopyable.hpp>
namespace apache { namespace thrift { namespace concurrency {
@@ -100,7 +101,7 @@ private:
boost::shared_ptr<impl> impl_;
};
-class Guard {
+class Guard : boost::noncopyable {
public:
Guard(const Mutex& value, int64_t timeout = 0) : mutex_(&value) {
if (timeout == 0) {