X-Git-Url: https://mattmccutchen.net/rsync/rsync.git/blobdiff_plain/58a79f4b44593996e53a9bfc94b56006ea86c2ec..9a54a640f74dcaeb03ef99799a5320b3eb77f7ec:/main.c diff --git a/main.c b/main.c index 4f3729e8..66412916 100644 --- a/main.c +++ b/main.c @@ -1521,9 +1521,10 @@ int main(int argc,char *argv[]) exit_cleanup(RERR_SYNTAX); } - /* we set a 0 umask so that correct file permissions can be - * carried across */ - orig_umask = umask(0); + /* Get the umask for use in permission calculations. We no longer set + * it to zero; that is ugly and pointless now that all the callers that + * relied on it have been reeducated to work with default ACLs. */ + umask(orig_umask = umask(0)); #if defined CONFIG_LOCALE && defined HAVE_SETLOCALE setlocale(LC_CTYPE, "");