[buildd-tools-devel] Bug#800317: Bug#800317: group sbuild detection slightly broken

Johannes Schauer josch at debian.org
Fri Dec 25 12:03:10 UTC 2015


Control: tag -1 + patch pending

Hi,

On Mon, 28 Sep 2015 07:57:13 +0200 Christoph Berg <myon at debian.org> wrote:
> Re: Johannes Schauer 2015-09-27 <20150927193746.1941.95441 at localhost>
> > Indeed. Do you think it would be sufficient to change above error message to:
> > 
> >  | User $user is currently not a member of group sbuild. Please run:
> >  | sudo sbuild-adduser $LOGNAME
> >  | And then logout and re-login or use `newgrp sbuild`
> > 
> > Thanks!
> 
> The above should be sufficient, unless sbuild actually tries to detect the
> "not logged in again yet" situation. (I haven't checked the code.)

I have the following patch in my local sbuild git which should fix this bug and
should be part of the next sbuild release:

--- a/lib/Sbuild.pm
+++ b/lib/Sbuild.pm
@@ -374,8 +374,9 @@ sub check_group_membership () {
     }
 
     if (!$in_group) {
-       print STDERR "User $user is not currently a member of group sbuild, but is in the system group database\n";
-       print STDERR "You need to log in again to gain sbuild group privileges\n";
+       print STDERR "User $user is not currently an effective member of group sbuild. Please run:\n";
+       print STDERR " sudo sbuild-adduser $user\n";
+       print STDERR "And then either log out and log in again or use `newgrp sbuild` to gain sbuild group privileges\n";
        exit(1);
     }
 


Thanks!

cheers, josch
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: signature
URL: <http://lists.alioth.debian.org/pipermail/buildd-tools-devel/attachments/20151225/86e51631/attachment.sig>


More information about the Buildd-tools-devel mailing list