From 45d5ad751f327b10e7256d448d5595daa82c98c4 Mon Sep 17 00:00:00 2001 From: Gerrit Uitslag Date: Tue, 15 Oct 2013 13:03:30 +0200 Subject: fix php strict notices --- inc/parser/handler.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'inc/parser') diff --git a/inc/parser/handler.php b/inc/parser/handler.php index 1de981b48..63a4104e2 100644 --- a/inc/parser/handler.php +++ b/inc/parser/handler.php @@ -70,7 +70,7 @@ class Doku_Handler { */ function plugin($match, $state, $pos, $pluginname){ $data = array($match); - $plugin =& plugin_load('syntax',$pluginname); + $plugin = plugin_load('syntax',$pluginname); if($plugin != null){ $data = $plugin->handle($match, $state, $pos, $this); } -- cgit v1.2.3 From 443e135d59e9d227eec818dabf9ee64d7a73d474 Mon Sep 17 00:00:00 2001 From: Christopher Smith Date: Wed, 16 Oct 2013 22:04:01 +0100 Subject: replace boolean conditional checks on possibly uninitialized vars with \!empty/empty/isset as appropriate --- inc/parser/handler.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'inc/parser') diff --git a/inc/parser/handler.php b/inc/parser/handler.php index 63a4104e2..bb284136f 100644 --- a/inc/parser/handler.php +++ b/inc/parser/handler.php @@ -653,8 +653,8 @@ function Doku_Handler_Parse_Media($match) { //parse width and height if(preg_match('#(\d+)(x(\d+))?#i',$param,$size)){ - ($size[1]) ? $w = $size[1] : $w = null; - ($size[3]) ? $h = $size[3] : $h = null; + !empty($size[1]) ? $w = $size[1] : $w = null; + !empty($size[3]) ? $h = $size[3] : $h = null; } else { $w = null; $h = null; -- cgit v1.2.3 From 53bfcb5964deda22607f47981b51d17e0f48d7ca Mon Sep 17 00:00:00 2001 From: Christopher Smith Date: Wed, 16 Oct 2013 22:06:51 +0100 Subject: initialize $inParagraph before use --- inc/parser/handler.php | 1 + 1 file changed, 1 insertion(+) (limited to 'inc/parser') diff --git a/inc/parser/handler.php b/inc/parser/handler.php index bb284136f..8ae991209 100644 --- a/inc/parser/handler.php +++ b/inc/parser/handler.php @@ -1432,6 +1432,7 @@ class Doku_Handler_Table { class Doku_Handler_Block { var $calls = array(); var $skipEol = false; + var $inParagraph = false; // Blocks these should not be inside paragraphs var $blockOpen = array( -- cgit v1.2.3