aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorJon Skeet <skeet@pobox.com>2015-08-05 09:11:25 +0100
committerJon Skeet <skeet@pobox.com>2015-08-05 09:11:25 +0100
commit607940321c8ceeb80ec1099d94add8eef86825e5 (patch)
treea9ccd19f451afbbba95814ff8ea5bf8b15fc841a /src
parentd77d70d227b648ac8c36183ac9d85cf39f782978 (diff)
parentc13a612dc473ff0678602892121c3101c6890abb (diff)
downloadprotobuf-607940321c8ceeb80ec1099d94add8eef86825e5.tar.gz
protobuf-607940321c8ceeb80ec1099d94add8eef86825e5.tar.bz2
protobuf-607940321c8ceeb80ec1099d94add8eef86825e5.zip
Merge pull request #689 from jskeet/fix-eof
C# conformance tests
Diffstat (limited to 'src')
-rw-r--r--src/google/protobuf/compiler/csharp/csharp_message.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/google/protobuf/compiler/csharp/csharp_message.cc b/src/google/protobuf/compiler/csharp/csharp_message.cc
index 6ea568ca..ea722455 100644
--- a/src/google/protobuf/compiler/csharp/csharp_message.cc
+++ b/src/google/protobuf/compiler/csharp/csharp_message.cc
@@ -428,7 +428,8 @@ void MessageGenerator::GenerateMergingMethods(io::Printer* printer) {
" if (pb::WireFormat.IsEndGroupTag(tag)) {\n"
" return;\n"
" }\n"
- " break;\n"); // Note: we're ignoring unknown fields here.
+ " input.ConsumeLastField();\n" // We're not storing the data, but we still need to consume it.
+ " break;\n");
for (int i = 0; i < fields_by_number().size(); i++) {
const FieldDescriptor* field = fields_by_number()[i];
internal::WireFormatLite::WireType wt =