diff --git a/docs/handbook/tutorial.rst b/docs/handbook/tutorial.rst index 6b4add945..80766a5ad 100644 --- a/docs/handbook/tutorial.rst +++ b/docs/handbook/tutorial.rst @@ -484,9 +484,9 @@ Reading from a string :: - import StringIO + import io - im = Image.open(StringIO.StringIO(buffer)) + im = Image.open(io.StringIO(buffer)) Note that the library rewinds the file (using ``seek(0)``) before reading the image header. In addition, seek will also be used when the image data is read