From dd09773e60e60047e122f22741c8717ebb117d7c Mon Sep 17 00:00:00 2001 From: Charlie Fenton Date: Fri, 2 Jul 2021 04:34:00 -0700 Subject: [PATCH] Mac installer: Minor fix to debugging print statement; add a comment --- mac_installer/PostInstall.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/mac_installer/PostInstall.cpp b/mac_installer/PostInstall.cpp index 145ce75cb9..5650410341 100644 --- a/mac_installer/PostInstall.cpp +++ b/mac_installer/PostInstall.cpp @@ -2269,14 +2269,16 @@ int optionally_install_rosetta2() { fflush(stdout); if (err) return err; - // Wait up to 20 seconds for system to install Rosetta 2 + // Wait up to 20 seconds for system to install Rosetta 2. + // My tests seem to show that callPosixSpawn() does not return until after + // installaton of Rosetta 2 is complete, but do this anyway to be sure. for (;;) { err = check_rosetta2_installed(); if (err == 0) break; if (++i > 20) break; boinc_sleep(1); } - printf("check_rosetta2_installed() returned %d after %d seconds.\n", err, i+1); + printf("check_rosetta2_installed() returned %d after %d seconds.\n", err, i); fflush(stdout); } return err;