aboutsummaryrefslogtreecommitdiffstats
path: root/fetchmail.c
diff options
context:
space:
mode:
authorMatthias Andree <matthias.andree@gmx.de>2005-07-20 15:25:09 +0000
committerMatthias Andree <matthias.andree@gmx.de>2005-07-20 15:25:09 +0000
commit13208ecc1ba2826b9f62e36860493565c1628590 (patch)
treeac05e6308a6791471ab9fce30286c1d6498602be /fetchmail.c
parentf031aecee9d45d9604b87e9f26ca3e6252ff6a76 (diff)
downloadfetchmail-13208ecc1ba2826b9f62e36860493565c1628590.tar.gz
fetchmail-13208ecc1ba2826b9f62e36860493565c1628590.tar.bz2
fetchmail-13208ecc1ba2826b9f62e36860493565c1628590.zip
Print a warning that running fetchmail as root is discouraged.
svn path=/trunk/; revision=4145
Diffstat (limited to 'fetchmail.c')
-rw-r--r--fetchmail.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/fetchmail.c b/fetchmail.c
index 6079f4ff..d9ef9927 100644
--- a/fetchmail.c
+++ b/fetchmail.c
@@ -155,6 +155,10 @@ int main(int argc, char **argv)
iana_charset = "US-ASCII";
#endif
+ if (getuid() == 0) {
+ report(stderr, GT_("WARNING: Running as root is discouraged.\n"));
+ }
+
/*
* Note: because we can't initialize reporting before we know whether
* syslog is supposed to be on, this message will go to stdout and