Skip to content

Commit

Permalink
slight simplification to #33 fix
Browse files Browse the repository at this point in the history
  • Loading branch information
stevengj committed Aug 2, 2013
1 parent 53b1bfc commit 5b40430
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/io.jl
Original file line number Diff line number Diff line change
Expand Up @@ -214,7 +214,7 @@ end
function jl_IO_writelines(self_::PyPtr, arg_::PyPtr)
try
io = unsafe_pyjlwrap_to_objref(self_)::IO
for s in PyVector{String}(pyincref(PyObject(arg_)))
for s in PyVector{String}(pyincref(arg_))
write(io, s)
end
ccall((@pysym :Py_IncRef), Void, (PyPtr,), pynothing::PyPtr)
Expand Down Expand Up @@ -263,7 +263,7 @@ end
function jl_IO_readinto(self_::PyPtr, arg_::PyPtr)
try
io = unsafe_pyjlwrap_to_objref(self_)::IO
b = convert(Vector{Uint8}, pyincref(PyObject(arg_)))
b = convert(Vector{Uint8}, pyincref(arg_))
return pyincref(PyObject(readbytes!(io, b))).o
catch e
ioraise(e)
Expand All @@ -274,7 +274,7 @@ end
function jl_IO_write(self_::PyPtr, arg_::PyPtr)
try
io = unsafe_pyjlwrap_to_objref(self_)::IO
b = convert(Vector{Uint8}, pyincref(PyObject(arg_)))
b = convert(Vector{Uint8}, pyincref(arg_))
return pyincref(PyObject(write(io, b))).o
catch e
ioraise(e)
Expand Down

0 comments on commit 5b40430

Please sign in to comment.