Fixed issue 459, variables not defined for exec in PHP 5.3.

master
Mehdi Kabab 2010-05-11 10:13:38 +02:00
parent 28ce82c6f6
commit 8f914c44a1
1 changed files with 4 additions and 0 deletions

View File

@ -196,6 +196,8 @@ class IDF_Plugin_SyncGit_Serve
if (!file_exists($fullpath)) { if (!file_exists($fullpath)) {
mkdir($fullpath, 0750, true); mkdir($fullpath, 0750, true);
} }
$out = array();
$res = 0;
exec(sprintf(Pluf::f('idf_exec_cmd_prefix', ''). exec(sprintf(Pluf::f('idf_exec_cmd_prefix', '').
Pluf::f('git_path', 'git').' --git-dir=%s init', escapeshellarg($fullpath)), Pluf::f('git_path', 'git').' --git-dir=%s init', escapeshellarg($fullpath)),
$out, $res); $out, $res);
@ -214,6 +216,8 @@ class IDF_Plugin_SyncGit_Serve
$fullpath.'/hooks/post-update')); $fullpath.'/hooks/post-update'));
return; return;
} }
$out = array();
$res = 0;
exec(sprintf(Pluf::f('idf_exec_cmd_prefix', '').'ln -s %s %s', exec(sprintf(Pluf::f('idf_exec_cmd_prefix', '').'ln -s %s %s',
escapeshellarg($p), escapeshellarg($p),
escapeshellarg($fullpath.'/hooks/post-update')), escapeshellarg($fullpath.'/hooks/post-update')),