浏览代码

Merge pull request #5033 from xfxyjwf/up

Fix issues discovered in up-integration.
Feng Xiao 7 年之前
父节点
当前提交
d39c7ef6eb
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/google/protobuf/message.h

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

@@ -1160,7 +1160,7 @@ const T* DynamicCastToGenerated(const Message* from) {
   (void)unused;
 
 #ifdef GOOGLE_PROTOBUF_NO_RTTI
-  bool ok = &T::default_instance()->GetReflection() == from->GetReflection();
+  bool ok = T::default_instance().GetReflection() == from->GetReflection();
   return ok ? down_cast<const T*>(from) : nullptr;
 #else
   return dynamic_cast<const T*>(from);