Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(25)

Unified Diff: third_party/protobuf/src/google/protobuf/stubs/once.h

Issue 1322483002: Revert https://codereview.chromium.org/1291903002 (protobuf roll). (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/protobuf/src/google/protobuf/stubs/once.h
diff --git a/third_party/protobuf/src/google/protobuf/stubs/once.h b/third_party/protobuf/src/google/protobuf/stubs/once.h
index 9522b22a1c22657e5154734b86e4a417bb081d39..9f1c5fc6469f5fa654a2d6b1c2eea9230ce5c1b8 100644
--- a/third_party/protobuf/src/google/protobuf/stubs/once.h
+++ b/third_party/protobuf/src/google/protobuf/stubs/once.h
@@ -1,6 +1,6 @@
// Protocol Buffers - Google's data interchange format
// Copyright 2008 Google Inc. All rights reserved.
-// https://developers.google.com/protocol-buffers/
+// http://code.google.com/p/protobuf/
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
@@ -79,7 +79,6 @@
#define GOOGLE_PROTOBUF_STUBS_ONCE_H__
#include <google/protobuf/stubs/atomicops.h>
-#include <google/protobuf/stubs/callback.h>
#include <google/protobuf/stubs/common.h>
namespace google {
@@ -136,24 +135,6 @@ inline void GoogleOnceInit(ProtobufOnceType* once, void (*init_func)(Arg*),
#endif // GOOGLE_PROTOBUF_NO_THREAD_SAFETY
-class GoogleOnceDynamic {
- public:
- GoogleOnceDynamic() : state_(GOOGLE_PROTOBUF_ONCE_INIT) { }
-
- // If this->Init() has not been called before by any thread,
- // execute (*func_with_arg)(arg) then return.
- // Otherwise, wait until that prior invocation has finished
- // executing its function, then return.
- template<typename T>
- void Init(void (*func_with_arg)(T*), T* arg) {
- GoogleOnceInit<T>(&this->state_,
- func_with_arg,
- arg);
- }
- private:
- ProtobufOnceType state_;
-};
-
#define GOOGLE_PROTOBUF_DECLARE_ONCE(NAME) \
::google::protobuf::ProtobufOnceType NAME = GOOGLE_PROTOBUF_ONCE_INIT
« no previous file with comments | « third_party/protobuf/src/google/protobuf/stubs/mutex.h ('k') | third_party/protobuf/src/google/protobuf/stubs/once.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698