mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-08 19:21:40 +09:00
debugOutput시 XMLPRC request의 로그가 쌓이지 않는 버그 수정
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@4076 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
173c58918c
commit
7cb05f6301
2 changed files with 9 additions and 15 deletions
|
|
@ -144,7 +144,7 @@
|
|||
* tail -f ./files/_debug_message.php로 하여 console로 확인하면 편리함\n
|
||||
**/
|
||||
function _debugOutput() {
|
||||
if(!__DEBUG__ || Context::getResponseMethod()!='HTML' ) return;
|
||||
if(!__DEBUG__) return;
|
||||
|
||||
$end = getMicroTime();
|
||||
|
||||
|
|
@ -189,9 +189,9 @@
|
|||
// 전체 실행 시간 작성
|
||||
$buff .= sprintf("\tTotal elapsed time \t\t: %0.5f sec", $end-__StartTime__);
|
||||
|
||||
if(__DEBUG_OUTPUT__==1) return $buff;
|
||||
if(__DEBUG_OUTPUT__==1 && Context::getResponseMethod()=='HTML') return "<!--\r\n".$buff."\r\n-->";
|
||||
|
||||
debugPrint($buff, false);
|
||||
if(__DEBUG_OUTPUT__==0) debugPrint($buff, false);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -310,20 +310,14 @@
|
|||
* tail -f ./files/_debug_message.php 하여 계속 살펴 볼 수 있다
|
||||
**/
|
||||
function debugPrint($buff = null, $display_line = true) {
|
||||
//if(!$buff) return;
|
||||
$debug_file = "./files/_debug_message.php";
|
||||
$buff = sprintf("%s\n",print_r($buff,true));
|
||||
|
||||
if(__DEBUG_OUTPUT__ == 1) {
|
||||
print sprintf("<!--\n%s\n-->", print_r($buff,true));
|
||||
} else {
|
||||
$debug_file = "./files/_debug_message.php";
|
||||
$buff = sprintf("%s\n",print_r($buff,true));
|
||||
if($display_line) $buff = "\n====================================\n".$buff."------------------------------------\n";
|
||||
|
||||
if($display_line) $buff = "\n====================================\n".$buff."------------------------------------\n";
|
||||
|
||||
if(@!$fp = fopen($debug_file,"a")) return;
|
||||
fwrite($fp, $buff);
|
||||
fclose($fp);
|
||||
}
|
||||
if(@!$fp = fopen($debug_file,"a")) return;
|
||||
fwrite($fp, $buff);
|
||||
fclose($fp);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue