Prechádzať zdrojové kódy

Export fixed_address_empty_string

commit 98835fb8f8 broke use of protobuf as shared library on Windows. Example
error message:

  error LNK2001: unresolved external symbol "class google::protobuf::internal::ExplicitlyConstructed<class std::basic_string<char,struct std::char_traits<char>,class std::allocator<char> > > google::protobuf::internal::fixed_address_empty_string"
Thomas Sondergaard 8 rokov pred
rodič
commit
c699788573

+ 1 - 1
src/google/protobuf/generated_message_util.h

@@ -111,7 +111,7 @@ class ExplicitlyConstructed {
 
 
 // Default empty string object. Don't use this directly. Instead, call
 // Default empty string object. Don't use this directly. Instead, call
 // GetEmptyString() to get the reference.
 // GetEmptyString() to get the reference.
-extern ExplicitlyConstructed< ::std::string> fixed_address_empty_string;
+LIBPROTOBUF_EXPORT extern ExplicitlyConstructed< ::std::string> fixed_address_empty_string;
 LIBPROTOBUF_EXPORT extern ProtobufOnceType empty_string_once_init_;
 LIBPROTOBUF_EXPORT extern ProtobufOnceType empty_string_once_init_;
 LIBPROTOBUF_EXPORT void InitEmptyString();
 LIBPROTOBUF_EXPORT void InitEmptyString();