Skip to content

Commit 617e255

Browse files
authored
Merge pull request #8409 from srago/protoc-fix
add error returns missing from protoc to prevent it from exiting with…
2 parents f579403 + 57e09ad commit 617e255

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

src/google/protobuf/compiler/command_line_interface.cc

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -586,10 +586,12 @@ bool CommandLineInterface::GeneratorContextImpl::WriteAllToZip(
586586

587587
if (stream.GetErrno() != 0) {
588588
std::cerr << filename << ": " << strerror(stream.GetErrno()) << std::endl;
589+
return false;
589590
}
590591

591592
if (!stream.Close()) {
592593
std::cerr << filename << ": " << strerror(stream.GetErrno()) << std::endl;
594+
return false;
593595
}
594596

595597
return true;

0 commit comments

Comments
 (0)