This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "FusionForge".

The branch, 6.0 has been updated
       via  1a6dc7231c562105613e42a9eb2127878b9e5bf0 (commit)
       via  1da92a5bb4f80f42df5d4cc03435d9641a771ee3 (commit)
      from  999fa21891c3fa5724582a99509126f283bd34ff (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=1a6dc7231c562105613e42a9eb2127878b9e5bf0

commit 1a6dc7231c562105613e42a9eb2127878b9e5bf0
Author: Sylvain Beucler <[email protected]>
Date:   Thu Oct 15 10:11:04 2015 +0200

    scmgit: stats: match e-mail case-insensitively

diff --git a/src/plugins/scmgit/common/GitPlugin.class.php 
b/src/plugins/scmgit/common/GitPlugin.class.php
index 8f4ea26..8ef6b88 100644
--- a/src/plugins/scmgit/common/GitPlugin.class.php
+++ b/src/plugins/scmgit/common/GitPlugin.class.php
@@ -734,7 +734,7 @@ control over it to the project's administrator.");
                                        if ($result) {
                                                // Author line
                                                $last_user = $matches['name'];
-                                               $user2email[$last_user] = 
strtolower($matches['mail']);
+                                               $user2email[$last_user] = 
$matches['mail'];
                                                if 
(!isset($usr_adds[$last_user])) {
                                                        $usr_adds[$last_user] = 
0;
                                                        
$usr_updates[$last_user] = 0;
@@ -791,8 +791,8 @@ control over it to the project's administrator.");
                                if ($u) {
                                        $user_id = $u->getID();
                                } else {
-                                       $res=db_query_params('SELECT user_id 
FROM users WHERE lower(realname)=$1 OR email=$2',
-                                               array(strtolower($user), 
$user2email[$user]));
+                                       $res=db_query_params('SELECT user_id 
FROM users WHERE lower(realname)=$1 OR lower(email)=$2',
+                                               array(strtolower($user), 
strtolower($user2email[$user])));
                                        if ($res && db_numrows($res) > 0) {
                                                $user_id = 
db_result($res,0,'user_id');
                                        } else {

https://scm.fusionforge.org/anonscm/gitweb/?p=fusionforge/fusionforge.git;a=commitdiff;h=1da92a5bb4f80f42df5d4cc03435d9641a771ee3

commit 1da92a5bb4f80f42df5d4cc03435d9641a771ee3
Author: Sylvain Beucler <[email protected]>
Date:   Thu Oct 15 09:49:45 2015 +0200

    scmgit: stats: drop only bad UTF-8, not all non-ASCII chars

diff --git a/src/plugins/scmgit/common/GitPlugin.class.php 
b/src/plugins/scmgit/common/GitPlugin.class.php
index 18ce98b..8f4ea26 100644
--- a/src/plugins/scmgit/common/GitPlugin.class.php
+++ b/src/plugins/scmgit/common/GitPlugin.class.php
@@ -725,11 +725,10 @@ control over it to the project's administrator.");
                        $last_user    = "";
                        while (!feof($pipe) && $data = fgets($pipe)) {
                                $line = trim($data);
-                               // Drop bad UTF-8 - it's quite hard to make git 
output non-UTF-8
-                               // (e.g. by enforcing an unknown encoding) - 
but some users do!
-                               // and this makes PostgreSQL choke
-                               // this fix removes tabs in line. the regex 
used in short-commit stats line has been changed accordingly.
-                               $line = preg_replace('/[^(\x20-\x7F)]/','', 
$line);
+                               // Replace bad UTF-8 with '?' - it's quite hard 
to make git output non-UTF-8
+                               // (e.g. with i18n.commitEncoding = unknown) - 
but some users do!
+                               // and this makes PostgreSQL choke (SQL> ERROR: 
 invalid byte sequence for encoding "UTF8": 0xf9)
+                               $line = mb_convert_encoding($line, 'UTF-8', 
'UTF-8');
                                if (strlen($line) > 0) {
                                        $result = preg_match("/^(?P<name>.+) 
<(?P<mail>.+)>/", $line, $matches);
                                        if ($result) {
@@ -746,7 +745,7 @@ control over it to the project's administrator.");
                                                $usr_commits[$last_user]++;
                                        } else {
                                                // Short-commit stats line
-                                               $result = 
preg_match("/^(?P<mode>[AMD])(?P<file>.+)$/", $line, $matches);
+                                               $result = 
preg_match("/^(?P<mode>[AMD])\s+(?P<file>.+)$/", $line, $matches);
                                                if (!$result) continue;
                                                if ($last_user == "") continue;
                                                if 
(!isset($usr_adds[$last_user])) $usr_adds[$last_user] = 0;

-----------------------------------------------------------------------

Summary of changes:
 src/plugins/scmgit/common/GitPlugin.class.php | 17 ++++++++---------
 1 file changed, 8 insertions(+), 9 deletions(-)


hooks/post-receive
-- 
FusionForge

_______________________________________________
Fusionforge-commits mailing list
[email protected]
http://lists.fusionforge.org/cgi-bin/mailman/listinfo/fusionforge-commits

Reply via email to