Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* Blockly fixes * Objects fixes
- Loading branch information
Showing
7 changed files
with
61 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Original file line | Diff line number | Diff line change |
---|---|---|---|
@@ -1,42 +1,42 @@ | |||
<?php | <?php | ||
|
|
||
chdir(dirname(__FILE__) . '/../'); | chdir(dirname(__FILE__) . '/../'); | ||
|
|
||
include_once './config.php'; | include_once './config.php'; | ||
include_once './lib/loader.php'; | include_once './lib/loader.php'; | ||
include_once './lib/threads.php'; | include_once './lib/threads.php'; | ||
|
|
||
set_time_limit(0); | set_time_limit(0); | ||
|
|
||
include_once("./load_settings.php"); | include_once("./load_settings.php"); | ||
include_once(DIR_MODULES . "control_modules/control_modules.class.php"); | include_once(DIR_MODULES . "control_modules/control_modules.class.php"); | ||
|
|
||
$ctl = new control_modules(); | $ctl = new control_modules(); | ||
|
|
||
include_once(DIR_MODULES . 'pinghosts/pinghosts.class.php'); | include_once(DIR_MODULES . 'pinghosts/pinghosts.class.php'); | ||
|
|
||
$pinghosts = new pinghosts(); | $pinghosts = new pinghosts(); | ||
|
|
||
$checked_time = 0; | $checked_time = 0; | ||
|
|
||
echo date("H:i:s") . " running " . basename(__FILE__) . PHP_EOL; | echo date("H:i:s") . " running " . basename(__FILE__) . PHP_EOL; | ||
|
|
||
while (1) | while (1) | ||
{ | { | ||
if (time() - $checked_time > 10) | if (time() - $checked_time > 10) | ||
{ | { | ||
$checked_time = time(); | $checked_time = time(); | ||
setGlobal((str_replace('.php', '', basename(__FILE__))) . 'Run', time(), 1); | setGlobal((str_replace('.php', '', basename(__FILE__))) . 'Run', time(), 1); | ||
|
|
||
// checking all hosts | // checking all hosts | ||
$pinghosts->checkAllHosts(1); | $pinghosts->checkAllHosts(); | ||
} | } | ||
|
|
||
if (file_exists('./reboot') || IsSet($_GET['onetime'])) | if (file_exists('./reboot') || IsSet($_GET['onetime'])) | ||
{ | { | ||
exit; | exit; | ||
} | } | ||
sleep(1); | sleep(1); | ||
} | } | ||
|
|
||
DebMes("Unexpected close of cycle: " . basename(__FILE__)); | DebMes("Unexpected close of cycle: " . basename(__FILE__)); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters