改名
This commit is contained in:
@@ -99,7 +99,7 @@ class ErrorHandler extends Component implements ErrorInterface
|
|||||||
$error[0] = 500;
|
$error[0] = 500;
|
||||||
}
|
}
|
||||||
|
|
||||||
$data = JSON::to(500, 'Error : ' . $error[1], $path);
|
$data = JSON::to(500, $error[1], $path);
|
||||||
|
|
||||||
Snowflake::app()->getLogger()->error($data, 'error');
|
Snowflake::app()->getLogger()->error($data, 'error');
|
||||||
|
|
||||||
|
|||||||
@@ -184,6 +184,7 @@ class ServerInotify extends Process
|
|||||||
*/
|
*/
|
||||||
public function clearWatch()
|
public function clearWatch()
|
||||||
{
|
{
|
||||||
|
set_error_handler([$this, 'onErrorHandler']);
|
||||||
foreach ($this->watchFiles as $wd) {
|
foreach ($this->watchFiles as $wd) {
|
||||||
try {
|
try {
|
||||||
inotify_rm_watch($this->inotify, $wd);
|
inotify_rm_watch($this->inotify, $wd);
|
||||||
@@ -195,6 +196,15 @@ class ServerInotify extends Process
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
*/
|
||||||
|
protected function onErrorHandler()
|
||||||
|
{
|
||||||
|
$error = func_get_args();
|
||||||
|
print_r($error[1] . ' ' . $error[2] . ':' . $error[3]);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param $dir
|
* @param $dir
|
||||||
|
|||||||
Reference in New Issue
Block a user