[issue5147] MozillaCookieJar should not store leading whitespace in Magic header

2009-02-03 Thread Ajith Antony

New submission from Ajith Antony :

It seems that in the MozillaCookieJar library, the author accidently 
indented
the long string that represents the magic header of the Netscape 
compatible
cookie file.  This is not a problem for MozillaCookieJar as the regex to 
test
the magic header is not bound to the beginning of the line.

Other libraries, however, may bind the pattern match to the beginning of 
the
line, such as perl's HTTP::Cookies::Netscape.

For better compatibility of Netscape cookies files, the magic header 
must not
be indented.


Index: svn-python-lib/_MozillaCookieJar.py
===
--- svn-python-lib/_MozillaCookieJar.py (revision 69261)
+++ svn-python-lib/_MozillaCookieJar.py (working copy)
@@ -38,9 +38,9 @@
 """
 magic_re = "#( Netscape)? HTTP Cookie File"
 header = """\
-# Netscape HTTP Cookie File
-# http://www.netscape.com/newsref/std/cookie_spec.html
-# This is a generated file!  Do not edit.
+# Netscape HTTP Cookie File
+# http://www.netscape.com/newsref/std/cookie_spec.html
+# This is a generated file!  Do not edit.

 """

--
components: Library (Lib)
messages: 81100
nosy: aantony
severity: normal
status: open
title: MozillaCookieJar should not store leading whitespace in Magic header
type: behavior
versions: Python 2.4, Python 2.5, Python 2.6, Python 2.7, Python 3.0, Python 3.1

___
Python tracker 
<http://bugs.python.org/issue5147>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com



[issue5147] MozillaCookieJar should not store leading whitespace in Magic header

2010-06-25 Thread Ajith Antony

Ajith Antony  added the comment:

ok. Patch attached.  I think.

--
Added file: http://bugs.python.org/file17772/5147.dif

___
Python tracker 
<http://bugs.python.org/issue5147>
___
___
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com