[tbb-commits] [Git][tpo/applications/tor-browser-build][maint-12.0] Bug 40791: Make sure dmg2mar exits with an error when something failed

Richard Pospesel (@richard) git at gitlab.torproject.org
Fri Feb 17 16:42:44 UTC 2023



Richard Pospesel pushed to branch maint-12.0 at The Tor Project / Applications / tor-browser-build


Commits:
b7e2bdc3 by Nicolas Vigier at 2023-02-17T16:42:43+00:00
Bug 40791: Make sure dmg2mar exits with an error when something failed

If the child process failed, make sure we exit with an error in the
parent process too.


(cherry picked from commit cf22cd266c5892f683306b84ca6b1363258ed6ae)
- - - - -


1 changed file:

- tools/dmg2mar


Changes:

=====================================
tools/dmg2mar
=====================================
@@ -106,7 +106,11 @@ sub get_dmg_files_from_sha256sums {
 sub convert_files {
     my ($channel) = @_;
     my $pm = Parallel::ForkManager->new(get_nbprocs);
-    $pm->run_on_finish(sub { print "Finished $_[2]\n" });
+    $pm->run_on_finish(
+      sub {
+        exit_error "Failed while running $_[2]" unless $_[1] == 0;
+        print "Finished $_[2]\n";
+      });
     foreach my $file (get_dmg_files_from_sha256sums) {
         # The 'ja' locale is a special case: it is called 'ja-JP-mac'
         # internally on OSX, but the dmg file still uses 'ja' to avoid



View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/b7e2bdc3575cbcfe05591aa12df41ffd3cb0568c

-- 
View it on GitLab: https://gitlab.torproject.org/tpo/applications/tor-browser-build/-/commit/b7e2bdc3575cbcfe05591aa12df41ffd3cb0568c
You're receiving this email because of your account on gitlab.torproject.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.torproject.org/pipermail/tbb-commits/attachments/20230217/a020f96e/attachment.htm>


More information about the tbb-commits mailing list