Red Hat axp-list: Linux on Alpha (1995-2022)
 help / color / mirror / Atom feed
From: Michal Jaegermann <michal@ellpspace.math.ualberta.ca>
To: drepper@cygnus.com
Cc: axp-list@redhat.com, bj0rn@blox.se
Subject: incorrect lseek() function in glibc-2.0.7
Date: Wed, 17 Mar 1999 18:13:35 -0700 (MST)	[thread overview]
Message-ID: <199903180113.SAA08616@ellpspace.math.ualberta.ca> (raw)


lseek from glibc-2.0.7 is broken on Alpha.  It is documented to
have the following prototype:

   off_t lseek(int fildes, off_t offset, int whence);

Here is a fragment of a trace from a new version of 'lsmod':
....
open("/dev/kmem", O_RDONLY)             = 4
lseek(4, 18446739675790475552, SEEK_SET) = 127435040
....
where the program attempts to seek to a location with a module
information in a memory. 18446739675790475552 happens to be
in hex 0xfffffc0007988120 and the return value is 0x7988120
so it is returned as 'int' and not 'off_t' - which, at least on
Alpha, are of different sizes.

What is more lseek() does not seem to be searching to a required
location as an attempt to read from there results in obviously
bogus values (all zeros).

  Michal Jaegermann,
  michal@harddata.com


             reply	other threads:[~1999-03-18  1:23 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-03-18  1:13 Michal Jaegermann [this message]
1999-03-19  6:12 ` incorrect lseek() function in glibc-2.0.7 Richard Henderson
1999-03-19  6:48   ` Michal Jaegermann
1999-03-19  7:16     ` Richard Henderson
1999-03-28  2:05       ` Michal Jaegermann
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox