[Git][reproducible-builds/disorderfs][master] Don't attempt to drop groups in multi-user mode when we are not root. (Closes:...

Chris Lamb gitlab at salsa.debian.org
Tue Apr 14 12:10:27 UTC 2020



Chris Lamb pushed to branch master at Reproducible Builds / disorderfs


Commits:
9e767d62 by Chris Lamb at 2020-04-14T12:59:57+01:00
Don't attempt to drop groups in multi-user mode when we are not root. (Closes: reproducible-builds/disorderfs#1)

- - - - -


1 changed file:

- disorderfs.cpp


Changes:

=====================================
disorderfs.cpp
=====================================
@@ -151,13 +151,13 @@ namespace {
 	struct Guard {
 		Guard ()
 		{
-			if (config.multi_user) {
+			if (config.multi_user && getuid() == 0) {
 				drop_privileges();
 			}
 		}
 		~Guard ()
 		{
-			if (config.multi_user) {
+			if (config.multi_user && getuid() == 0) {
 				restore_privileges();
 			}
 		}



View it on GitLab: https://salsa.debian.org/reproducible-builds/disorderfs/-/commit/9e767d62acfde48cbfab5d6728fea5f933cc0c74

-- 
View it on GitLab: https://salsa.debian.org/reproducible-builds/disorderfs/-/commit/9e767d62acfde48cbfab5d6728fea5f933cc0c74
You're receiving this email because of your account on salsa.debian.org.


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.reproducible-builds.org/pipermail/rb-commits/attachments/20200414/da3bb347/attachment.htm>


More information about the rb-commits mailing list