소스 검색

Merge pull request #2704 from liutikas/master

Fix compiler warnings about unused variables in wire_format.h
Feng Xiao 8 년 전
부모
커밋
aa78aeba98
1개의 변경된 파일3개의 추가작업 그리고 0개의 파일을 삭제
  1. 3 0
      src/google/protobuf/wire_format.h

+ 3 - 0
src/google/protobuf/wire_format.h

@@ -327,6 +327,9 @@ inline void WireFormat::VerifyUTF8StringNamedField(
 #ifdef GOOGLE_PROTOBUF_UTF8_VALIDATION_ENABLED
 #ifdef GOOGLE_PROTOBUF_UTF8_VALIDATION_ENABLED
   WireFormatLite::VerifyUtf8String(
   WireFormatLite::VerifyUtf8String(
       data, size, static_cast<WireFormatLite::Operation>(op), field_name);
       data, size, static_cast<WireFormatLite::Operation>(op), field_name);
+#else
+  // Avoid the compiler warning about unused variables.
+  (void)data; (void)size; (void)op; (void)field_name;
 #endif
 #endif
 }
 }