From 6845f591504e2a24608b531399882b4e07c0aed6 Mon Sep 17 00:00:00 2001 From: Loic d'Anterroches Date: Thu, 23 Jul 2009 23:33:08 +0200 Subject: [PATCH] Fixed variable used before being instanciated in the Mercurial backend. --- src/IDF/Scm/Mercurial.php | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/IDF/Scm/Mercurial.php b/src/IDF/Scm/Mercurial.php index c371844..507bd6f 100644 --- a/src/IDF/Scm/Mercurial.php +++ b/src/IDF/Scm/Mercurial.php @@ -261,9 +261,10 @@ class IDF_Scm_Mercurial extends IDF_Scm return $this->cache['branches']; } $out = array(); + $cmd = sprintf(Pluf::f('hg_path', 'hg').' branches -R %s', + escapeshellarg($this->repo)); $cmd = Pluf::f('idf_exec_cmd_prefix', '').$cmd; - exec(sprintf(Pluf::f('hg_path', 'hg').' branches -R %s', - escapeshellarg($this->repo)), $out); + exec($cmd, $out); $res = array(); foreach ($out as $b) { preg_match('/(\S+).*\S+:(\S+)/', $b, $match);