Why does "gksudo -u <anything other than root>" always return error code 1?
Asked by
Victor Engmark
This is normal:
$ gksudo -u root echo $HOME
/home/foobar
$ echo $?
0
But why does this return error code 1?
$ gksudo -u foobar echo $HOME
/home/foobar
$ echo $?
1
I'm running all commands as user foobar, which is a sudoer.
Interestingly, no error is reported by sudo in the same situation
$ sudo -u foobar echo $HOME
/home/foobar
$ echo $?
0
Using GKsu version 2.0.2.
Question information
- Language:
- English Edit question
- Status:
- Answered
- For:
- Ubuntu gksu Edit question
- Assignee:
- No assignee Edit question
- Last query:
- Last reply:
Can you help with this problem?
Provide an answer of your own, or ask Victor Engmark for more information if necessary.
To post a message you must log in.