From 6e129da180c7118b780052b75f11d1a9ebeae931 Mon Sep 17 00:00:00 2001 From: nachoparker Date: Sat, 30 Sep 2017 17:27:55 +0200 Subject: ncp-web: small fixes --- ncp-web/ncp-launcher.php | 1 + ncp-web/ncp-output.php | 6 ++++++ ncp-web/wizard/index.php | 12 ++++++++++++ 3 files changed, 19 insertions(+) (limited to 'ncp-web') diff --git a/ncp-web/ncp-launcher.php b/ncp-web/ncp-launcher.php index efb24761..4e5c518a 100644 --- a/ncp-web/ncp-launcher.php +++ b/ncp-web/ncp-launcher.php @@ -39,6 +39,7 @@ if ( $_POST['action'] == "cfgreq" ) // checkbox (yes/no) field if ( preg_match('/^(\w+)_=(yes|no)$/', $line, $matches) ) { + $checked = ""; if ( $matches[2] == "yes" ) $checked = "checked"; $output = $output . ""; diff --git a/ncp-web/ncp-output.php b/ncp-web/ncp-output.php index 750c71c6..6450250a 100644 --- a/ncp-web/ncp-output.php +++ b/ncp-web/ncp-output.php @@ -48,6 +48,12 @@ function follow($file) $size = 0; while (true) { + if ( !file_exists($file) ) + { + usleep(200000); // 0.2s + continue; + } + clearstatcache(); $currentSize = filesize($file); if ($size == $currentSize) diff --git a/ncp-web/wizard/index.php b/ncp-web/wizard/index.php index 1121b231..8ccf7ecd 100644 --- a/ncp-web/wizard/index.php +++ b/ncp-web/wizard/index.php @@ -9,6 +9,18 @@ -- cgit v1.2.3