Hi,

on exactly 1 of 5 machines here I have a problem
installing Gems. The tar unpacker just hangs. On the Gentoo
mailing list I found another user who encounters the same:

  <http://marc.info/?l=gentoo-user&m=118237767604668&w=4>
  <http://bugs.gentoo.org/show_bug.cgi?id=182826>

I analysed the problem and found that the IO#seek function
doesn't work proper. I larded the sources with output
statements and get the following output:

  seeking: 512 + 176
  rb_io_seek_m: whence=1
  rb_io_seek: pos=176, whence=0
  now at: 176
 
The outer two lines come from Tar#each_entry in rubygem's
`lib/rubygems/package.rb where I say

    if @io.respond_to? :seek
      # avoid reading...
      $stderr.puts "seeking: #{@io.tell} + #{size-entry.bytes_read}"
      @io.seek(size - entry.bytes_read, IO::SEEK_CUR)
      $stderr.puts "now at: #{@io.tell}"
      $stdin.gets
    else
      ..

The outer ones are printf statements in the rb_io_seek*
functions in `io.c.

    fprintf( stderr, "rb_io_seek_m: whence=%d\n", whence);
    return rb_io_seek(io, offset, whence);

and

    fprintf( stderr, "rb_io_seek: pos=%d, whence=%d\n", pos, whence);
    pos = io_seek(fptr, pos, whence);

I have no idea what goes wrong here.

In case you need further information, please tell me.

Bertram


-- 
Bertram Scharpf
Stuttgart, Deutschland/Germany
http://www.bertram-scharpf.de