Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP
Path: utzoo!mnetor!uunet!seismo!husc6!necntc!ima!haddock!karl
From: karl@haddock.ISC.COM (Karl Heuer)
Newsgroups: comp.unix.wizards
Subject: Re: Character special files cannot seek? (was Re: Seek on a pipe)
Message-ID: <712@haddock.ISC.COM>
Date: Fri, 10-Jul-87 20:19:08 EDT
Article-I.D.: haddock.712
Posted: Fri Jul 10 20:19:08 1987
Date-Received: Sun, 12-Jul-87 12:48:57 EDT
References: <7359@brl-adm.ARPA> <983@bobkat.UUCP> <5872@brl-smoke.ARPA> <1791@ttrdc.UUCP> <1088@killer.UUCP>
Reply-To: karl@haddock.ISC.COM (Karl Heuer)
Organization: Interactive Systems, Boston
Lines: 15

In article <1088@killer.UUCP> jfh@killer.UUCP (John Haugh) writes:
>I seem to recall that you can seek on [the c-special files mem, kmem, rdsk].
>I think the only things that leaves out are raw tapes and ttys.  Did anyone
>not really know this?

When I said "character special files are not seekable in general", I did not
mean to imply that all such were nonseekable, but that not all such were
seekable.  My article asserted that "isatty()" was not an appropriate test for
seekability.  The example of raw tape proves my statement.

I was assuming that the canseek() function, when presented with a c-special
file, should conservatively assume nonseekability.  In normal usage, this is
appropriate.

Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint