Use the nice macro to declare once-init control objects, like good little coders should. Otherwise the initialization routines never run on Mac. TODO: Investigate how this was broken.

This commit is contained in:
temporal 2009-08-01 07:30:49 +00:00
parent 9270a99d2e
commit f837b0066d
2 changed files with 2 additions and 2 deletions

View file

@ -798,7 +798,7 @@ namespace {
EncodedDescriptorDatabase* generated_database_ = NULL;
DescriptorPool* generated_pool_ = NULL;
GoogleOnceType generated_pool_init_;
GOOGLE_PROTOBUF_DECLARE_ONCE(generated_pool_init_);
void DeleteGeneratedPool() {
delete generated_database_;

View file

@ -76,7 +76,7 @@ struct ExtensionInfo {
typedef hash_map<pair<const MessageLite*, int>,
ExtensionInfo> ExtensionRegistry;
ExtensionRegistry* registry_ = NULL;
GoogleOnceType registry_init_;
GOOGLE_PROTOBUF_DECLARE_ONCE(registry_init_);
void DeleteRegistry() {
delete registry_;