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, Branch_5_3 has been updated
       via  bb99f90fd657496f59c5268379b49d596821afac (commit)
      from  0e77837663c41574a5953f6f0ec264dc41bfe1cf (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 -----------------------------------------------------------------
commit bb99f90fd657496f59c5268379b49d596821afac
Author: Sylvain Beucler <[email protected]>
Date:   Wed May 28 15:26:38 2014 +0200

    Tracker: fix file size for text attachments
    
    There used to be some code processing text files and attempting to convert 
them to UTF-8 in some situations.
    This code is long dead ($bin_data is not set and generates PHP warnings), 
but it still incorrectly reset $filesize.
    
    I got rid of the code entirely.

diff --git a/src/CHANGES b/src/CHANGES
index 4e1f5ce..6041edb 100644
--- a/src/CHANGES
+++ b/src/CHANGES
@@ -8,6 +8,7 @@ Fusionforge-5.3.1:
 * Tracker: fix email link in notification [#668] (TrivialDev)
 * Tracker: fix 404 in roadmap ajax call [#675] (TrivialDev)
 * Tracker: user-friendly error message when tracker is not enabled in a 
project (Inria)
+* Tracker: fix file size for text attachments (Inria)
 * Forum: fix database error in rare conditions when saving position (Inria)
 * Forum: fix incorrect access check to post moderation (Inria)
 * Web UI: Fix issue with old cookie that prevented user login after upgrade 
(Inria)
diff --git a/src/common/tracker/ArtifactFile.class.php 
b/src/common/tracker/ArtifactFile.class.php
index 7bf73c8..a8a4c03 100644
--- a/src/common/tracker/ArtifactFile.class.php
+++ b/src/common/tracker/ArtifactFile.class.php
@@ -142,14 +142,6 @@ class ArtifactFile extends Error {
                        $time = time();
                }
 
-               // If $filetype is "text/plain", $bin_data convert UTF-8 
encoding.
-               if (strcasecmp($filetype,"text/plain") === 0 &&
-                   function_exists('mb_convert_encoding') &&
-                   function_exists('mb_detect_encoding')) {
-                       $bin_data = 
mb_convert_encoding($bin_data,'UTF-8',mb_detect_encoding($bin_data, "auto"));
-                       $filesize = strlen($bin_data);
-               }
-
                db_begin();
 
                $res = db_query_params ('INSERT INTO artifact_file

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

Summary of changes:
 src/CHANGES                               |    1 +
 src/common/tracker/ArtifactFile.class.php |    8 --------
 2 files changed, 1 insertion(+), 8 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