summaryrefslogtreecommitdiffstats
path: root/courgette
diff options
context:
space:
mode:
Diffstat (limited to 'courgette')
-rw-r--r--courgette/courgette_tool.cc6
1 files changed, 4 insertions, 2 deletions
diff --git a/courgette/courgette_tool.cc b/courgette/courgette_tool.cc
index 225906e..fe08204 100644
--- a/courgette/courgette_tool.cc
+++ b/courgette/courgette_tool.cc
@@ -108,7 +108,8 @@ void Disassemble(const std::wstring& input_file,
courgette::DeleteEncodedProgram(encoded);
courgette::SinkStream sink;
- sinks.CopyTo(&sink);
+ if (!sinks.CopyTo(&sink))
+ Problem("Can't combine serialized encoded program streams.");
WriteSinkToFile(&sink, output_file);
}
@@ -157,7 +158,8 @@ void DisassembleAndAdjust(const std::wstring& program_file,
courgette::DeleteEncodedProgram(encoded);
courgette::SinkStream sink;
- sinks.CopyTo(&sink);
+ if (!sinks.CopyTo(&sink))
+ Problem("Can't combine serialized encoded program streams.");
WriteSinkToFile(&sink, output_file);
}