mercurial/pure/mpatch.py
changeset 28861 86db5cb55d46
parent 28782 f736f98e16ca
child 29695 f2846d546645
--- a/mercurial/pure/mpatch.py	Sun Apr 10 21:32:08 2016 +0000
+++ b/mercurial/pure/mpatch.py	Sun Apr 10 20:55:37 2016 +0000
@@ -7,10 +7,10 @@
 
 from __future__ import absolute_import
 
-import cStringIO
 import struct
 
-StringIO = cStringIO.StringIO
+from . import pycompat
+stringio = pycompat.stringio
 
 class mpatchError(Exception):
     """error raised when a delta cannot be decoded
@@ -66,7 +66,7 @@
     if not tl:
         return a
 
-    m = StringIO()
+    m = stringio()
 
     # load our original text
     m.write(a)