diff --git a/src/bin/docbook.py b/src/bin/docbook.py index cb1599216..d7c8d04d9 100755 --- a/src/bin/docbook.py +++ b/src/bin/docbook.py @@ -579,6 +579,7 @@ def run(self): if self.catalogs: args.append("-catalog:" + ";".join(self.catalogs)) + rc = 0 jopt = self.config.get("java-options", []) if self.debug: print(self._java) @@ -592,7 +593,9 @@ def run(self): print(f"\t{item}") else: cmd = [self._java] + jopt + ["-cp", cp] + [self.config["class"]] + args - subprocess.call(cmd) + rc = subprocess.call(cmd) + + return rc if __name__ == "__main__": @@ -602,7 +605,7 @@ def run(self): try: docbook = JavaClassRunner(sys.argv[1:]) docbook.compute_dependencies() - docbook.run() + sys.exit(docbook.run()) except JavaClassRunnerException as err: print(str(err)) sys.exit(1)