1.1 --- a/ItemSupport.py Tue Jan 14 16:36:01 2014 +0100
1.2 +++ b/ItemSupport.py Tue Jan 21 18:24:37 2014 +0100
1.3 @@ -2,7 +2,7 @@
1.4 """
1.5 MoinMoin - ItemSupport library
1.6
1.7 - @copyright: 2013 by Paul Boddie <paul@boddie.org.uk>
1.8 + @copyright: 2013, 2014 by Paul Boddie <paul@boddie.org.uk>
1.9 @license: GNU GPL (v2 or later), see COPYING.txt for details.
1.10 """
1.11
1.12 @@ -190,7 +190,7 @@
1.13
1.14 "Write the given 'item' to a file with the given 'next' item number."
1.15
1.16 - f = open(self.get_item_path(next), "w")
1.17 + f = open(self.get_item_path(next), "wb")
1.18 try:
1.19 f.write(item)
1.20 finally:
1.21 @@ -200,7 +200,7 @@
1.22
1.23 "Read the item with the given item 'number'."
1.24
1.25 - f = open(self.get_item_path(number))
1.26 + f = open(self.get_item_path(number), "rb")
1.27 try:
1.28 return f.read()
1.29 finally: