prewikka/master: HTML escape the Chart filename

[email protected] Wed, 13 Jan 2010 09:25:22 +0100 (CET)
Newsgroups gmane.comp.security.ids.prelude.cvs
Message-ID <[email protected]>
commit 48c8ea0752f988e24f13e9033a603a95bd9bab1a
Author: Yoann Vandoorselaere <[email protected]>
Date:   Wed Jan 13 09:25:39 2010 +0100

    HTML escape the Chart filename


========================================

 prewikka/Chart.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

========================================

diff --git a/prewikka/Chart.py b/prewikka/Chart.py
index 073eb93..291dc89 100644
--- a/prewikka/Chart.py
+++ b/prewikka/Chart.py
@@ -22,6 +22,7 @@
 import stat
 import time
 import base64
+import urllib
 import os, os.path
 import glob, tempfile
 
@@ -162,7 +163,7 @@ class ChartCommon:
 
         os.chmod(self._filename, 0644)
 
-        self._href = "prewikka/generated_images/%s" % (user or "") + "/" + os.path.basename(self._filename)
+        self._href = urllib.quote("prewikka/generated_images/%s" % (user or "") + "/" + os.path.basename(self._filename))
         os.umask(old_mask)
 
         return self._filename
_______________________________________________
Prelude-cvslog site list
[email protected]
http://lists.prelude-ids.org/mailman/listinfo/prelude-cvslog