Skip to content

SystemError seek: Bad file descriptor #14

@andrewcooke

Description

@andrewcooke
julia> using ZipFile

julia> io = ZipFile.Reader("test/gml/polblogs.zip").files[1]
ZipFile.ReadableFile(name=polblogs.gml, method=Deflate, uncompresssedsize=977839, compressedsize=93369, mtime=1.156468828e9)

julia> readline(io)
"Creator \"Lada Adamic on Tue Aug 15 2006\"\n"

julia> readline(io)
ERROR: SystemError: seek: Bad file descriptor
 in seek at ./iostream.jl:49
 in read at /home/andrew/.julia/v0.4/ZipFile/src/ZipFile.jl:410
 in readuntil at io.jl:174
 in readuntil at io.jl:156
 in readline at io.jl:217

the file is from http://www-personal.umich.edu/%7Emejn/netdata/polblogs.zip

if i do zmore or similar at the command line it has plenty more lines.

am i doing something dumb or is this an issue in your library? i was hoping it would a simple IO instance i could treat like a file (including rewind).

thanks.

edit:

   _       _ _(_)_     |  A fresh approach to technical computing
  (_)     | (_) (_)    |  Documentation: http://docs.julialang.org
   _ _   _| |_  __ _   |  Type "help()" for help.
  | | | | | | |/ _` |  |
  | | |_| | | | (_| |  |  Version 0.4.0-dev+5928 (2015-07-12 04:57 UTC)
 _/ |\__'_|_|_|\__'_|  |  Commit a9e0dd2 (5 days old master)
|__/                   |  x86_64-suse-linux

ZipFile was latest (Pkg.update()) at time of posting.

[edit2: cut + paste header from wrong julia - this was with 0.4 trunk, as updated above]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions