Commit:    bfef8080bed7733eef76800cf7960fdf67fead51
Author:    Alexander Moskaliov <ir...@php.net>         Sat, 7 Apr 2012 14:45:22 
+0400
Parents:   61cc09b1cbe8e3dcec3cf6b0447d942755c85a7c
Branches:  master

Link:       
http://git.php.net/?p=karma.git;a=commitdiff;h=bfef8080bed7733eef76800cf7960fdf67fead51

Log:
fix double bugs

Changed paths:
  M  lib/Git/BugsWebPostReceiveHook.php


Diff:
diff --git a/lib/Git/BugsWebPostReceiveHook.php 
b/lib/Git/BugsWebPostReceiveHook.php
index fa4ebb7..f96fe4a 100644
--- a/lib/Git/BugsWebPostReceiveHook.php
+++ b/lib/Git/BugsWebPostReceiveHook.php
@@ -41,17 +41,15 @@ class BugsWebPostReceiveHook extends ReceiveHook
                 \Git::GIT_EXECUTABLE,
                 $repourl
             );
-            exec($cmd, $output);
+            exec($cmd, $heads);
 
-            /* do we have heads? otherwise it's a new repo! */
-            $heads = implode(' ', $output);
-            $not   = count($output) > 0 ? sprintf('--not %s', 
escapeshellarg($heads)) : '';
+            $not   = count($output) > 0 ? ' --not ' . implode(' ', 
$this->escapeArrayShellArgs($heads)) : '';
             $cmd   = sprintf(
                 '%s --git-dir=%s log --pretty=format:"[%%ae] %%H %%s" %s %s',
                 \Git::GIT_EXECUTABLE,
                 $repourl,
-                $not,
-                escapeshellarg($new)
+                escapeshellarg($new),
+                $not
             );
             exec($cmd, $output);
         } elseif ($new != \Git::NULLREV) {


--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to