Bdale Garbee wrote:
I'm not immediately convinced that it would be any less surprising in general
for sudoedit to create the file with gid 0 than with the gid of the current
user.  Particularly since the -u option can be used to pick a user other than
root to run sudoedit as.

Thanks for pointing out the -u option, I did not think of that when I
submitted the bug report.  Indeed, "sudoedit -u user newfile" should
not create newfile with gid 0, that would not be right.

On many Debian systems, the default is for each user
to have a group with the same numeric id as their uid, but this is by no means
guaranteed, so it could be just as surprising to set the gid equal to the uid.

But it would be possible to get the desired gid from the /etc/passwd
file, for instance with getpwnam(3).  I think it would be correct if
"sudoedit [-u user] newfile" results in the same gid for newfile as
"sudo [-u user] $EDITOR newfile".   Do you agree to that?

I'm open to discussion about this, but for now I think the current behavior is
as good as any, and am going to change this to wishlist and tag it wontfix.





--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to