From: Nicolas Boisselier Date: Wed, 19 Nov 2014 23:25:06 +0000 (+0000) Subject: nico-crypto X-Git-Url: https://git.nbdom.net/?a=commitdiff_plain;h=00442f73c50ed3f5e523e6c7534ed55bb940dfc2;p=nb.git nico-crypto --- diff --git a/bin/nico-crypt-info b/bin/nico-crypt-info index 0d1bacbc..40f3a5ec 100755 --- a/bin/nico-crypt-info +++ b/bin/nico-crypt-info @@ -15,7 +15,7 @@ print "Usage: $0 [FILE] REGEXP [values|line|ini] if (@ARGV and $ARGV[0] !~ /^\.+$/ and -e $ARGV[0]) { $FILE = shift(@ARGV); } else { - &as_user(); + #&as_user(); } my $regexp = shift @ARGV; @@ -70,13 +70,13 @@ sub as_user { #@_ = ('su',$user,'-c',$0,@ARGV); #@_ = ('su',$user,'-c',join(' ',$0,@ARGV)); exec @_; - $_ = "su -l $user -c \"$0 ".join(" ",@ARGV)."\""; + $_ = "echo su $user -c \"$0 ".join(" ",@ARGV)."\""; #system($_); #die map{"$_\n"} @_; if ($cur eq 'root') { -exec $_; + exec $_; die "$NAME exec failed !"; } elsif ($cur ne $user) {