Print warnings if the user tries to run Privoxy as root
authorFabian Keil <fk@fabiankeil.de>
Sat, 14 Oct 2006 14:12:22 +0000 (14:12 +0000)
committerFabian Keil <fk@fabiankeil.de>
Sat, 14 Oct 2006 14:12:22 +0000 (14:12 +0000)
commit6fb0d5b897f16c213862a955482b17c14a02a729
treebf3668824ca732a325a6b7ab6bbd09e52e93efe6
parent802ee517a80ddfc91e1e2edaf8247092f8dee546
Print warnings if the user tries to run Privoxy as root
or if the script is run without root privileges;
only use "--user" if run with root privileges and
don't depend on $USER being set to root. Fixes BR 779781.

Apparently $USER isn't set on all systems,
but it also didn't work if the user only
increased her privileges with su or sudo,
but still had her real uid in $USER.

Thanks to Florian Effenberger for reporting.
privoxy-generic.init