Tags:
create new tag
, view all tags

Bug: Pipe chars in the comment field of the attachment table are not escaped

A pipe character generates a new column, thereby messing up the table. Pipe characters should be escaped / encoded/decoded.

Test case

View the attachment table at the bottom of BetterAttachmentTableForCairoRelease.

Environment

TWiki version: TWikiAlphaRelease
TWiki plugins: DefaultPlugin, EmptyPlugin, InterwikiPlugin
Server OS:  
Web server:  
Perl version:  
Client OS:  
Web Browser:  

-- ArthurClemens - 19 Jul 2004

Follow up

Fix record

The fix is now in SVN.

Index: Attach.pm
===================================================================
--- Attach.pm   (revision 1587)
+++ Attach.pm   (working copy)
@@ -199,6 +199,7 @@
        $row =~ s/%A_SIZE%/$attrSize/go;
   }

+  $comment =~ s/\|/|/g;
   $comment = " " unless ( $comment );
   $row =~ s/%A_COMMENT%/$comment/go;

-- PeterThoeny - 20 Jul 2004

Topic revision: r2 - 2004-07-20 - PeterThoeny
 
Twitter Delicious Facebook Digg Google Bookmarks E-mail LinkedIn Reddit StumbleUpon    
  • Download TWiki
TWiki logo Powered by Perl Hosted by OICcam.com Ideas, requests, problems regarding TWiki? Send feedback. Ask community in the support forum.
Copyright © 1999-2012 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.