From cf065a89685a694af955109455202f7dd5c378dd Mon Sep 17 00:00:00 2001 From: markusbloch Date: Mon, 25 Feb 2013 23:03:32 +0000 Subject: [PATCH] refusing define when creating a lan-ping check on a FritzBox with FHEM running under a nonroot username git-svn-id: https://fhem.svn.sourceforge.net/svnroot/fhem/trunk/fhem@2816 2b470e98-0d58-463d-a4d8-8e2adae1ed80 --- FHEM/73_PRESENCE.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/FHEM/73_PRESENCE.pm b/FHEM/73_PRESENCE.pm index 81500a7dc..3ce696250 100755 --- a/FHEM/73_PRESENCE.pm +++ b/FHEM/73_PRESENCE.pm @@ -118,7 +118,7 @@ PRESENCE_Define($$) return $msg; } - if($destination eq "fritzbox" and not $< == 0) + if(-X "/usr/bin/ctlmgr_ctl" and $destination eq "fritzbox" or $destination eq "lan-ping" and not $< == 0) { my $msg = "FHEM is not running under root (currently ".(getpwuid($<))[0].") This check can only performed with root access to the FritzBox";