diff --git a/settings/admin.php b/settings/admin.php
index d1ed6e75f501adb1244fadfaa52e4a3abdd2e7fc..2b96461309676af0f297da4e36510eec6f646cad 100644
--- a/settings/admin.php
+++ b/settings/admin.php
@@ -123,7 +123,7 @@ $template->printPage();
  * @return null|string
  */
 function findBinaryPath($program) {
-	if (OC_Helper::is_function_enabled('exec')) {
+	if (!\OC_Util::runningOnWindows() && \OC_Helper::is_function_enabled('exec')) {
 		exec('command -v ' . escapeshellarg($program) . ' 2> /dev/null', $output, $returnCode);
 		if ($returnCode === 0 && count($output) > 0) {
 			return escapeshellcmd($output[0]);