From: pk910 Date: Thu, 14 Feb 2013 07:37:12 +0000 (+0100) Subject: fixed delimiter of header graph X-Git-Url: http://git.pk910.de/?p=phpgitweb.git;a=commitdiff_plain;h=ce9f1b8b05ff571f6922460cf91b45aa5a119d94 fixed delimiter of header graph --- diff --git a/htdocs/lib/graph.class.php b/htdocs/lib/graph.class.php index 53f1aae..33c36b3 100644 --- a/htdocs/lib/graph.class.php +++ b/htdocs/lib/graph.class.php @@ -255,7 +255,7 @@ class graph_data_generator { foreach($this->data['branches'] as $branch) { if(array_key_exists('sticky', $branch) && $branch['sticky']) { $name = explode('/', $branch['name'][0], 3); - $dataadd .= "\n".$branch['id'].":".$name[2]; + $dataadd .= "//".$branch['id'].":".$name[2]; $branchcount++; } } @@ -295,8 +295,10 @@ class graph_image_generator { if(!GitConfig::GITGRAPH_ENABLE) return; $data = $this->parse_data($data); - if(!$data) - return; + if(!$data) { + header('Content-Type: text/plain'); + die(base64_decode("ICAgIC0tLS0tLS0tOi0tLS0tLS0tDQogICAgICAgICAgLC0iLC5fX19fX19fIC8NCiAgICAgICAgIC8gKSB8ICAgLC0tLS0nXA0KICAgICAgICAgXC9fX3wuLSINCiAgICAgICAgLl8vL19cXF8NCk5vdCB3aGF0IHlvdSBleHBlY3RlZCwgZWVlaD8=")); + } $count = $data['count']; if($count > $this->max_branches) @@ -315,7 +317,7 @@ class graph_image_generator { } private function display_header($header) { - $header = explode("\n",$header); + $header = explode("//",$header); $count = $header[0]; $header = array_slice($header, 1); if($count > $this->max_branches)