From e908db97f8883455a113ee0679548ce06210a159 Mon Sep 17 00:00:00 2001 From: Tom Mortensen Date: Wed, 15 Nov 2023 15:45:08 -0800 Subject: [PATCH] enclose arguemnt to emcmd() with single-quotes --- emhttp/plugins/dynamix/include/ToggleState.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/emhttp/plugins/dynamix/include/ToggleState.php b/emhttp/plugins/dynamix/include/ToggleState.php index 22b09c692..63e4e87dc 100644 --- a/emhttp/plugins/dynamix/include/ToggleState.php +++ b/emhttp/plugins/dynamix/include/ToggleState.php @@ -19,7 +19,7 @@ $name = $_POST['name']??''; $action = $_POST['action']??''; function emcmd($cmd) { - exec("emcmd $cmd"); + exec("emcmd '$cmd'"); } switch ($device) { case 'New':