From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Mon, 20 Oct 2008 03:26:45 -0400 From: Nathaniel W Filardo To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> Message-ID: <20081020072645.GJ4216@masters10.cs.jhu.edu> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="z8Ydz/NZAVzoOg+6" Content-Disposition: inline User-Agent: Mutt/1.5.18 (2008-05-17) Subject: [9fans] What's so special about seek() ? Topicbox-Message-UUID: 20dd205a-ead4-11e9-9d60-3106f5b1d025 --z8Ydz/NZAVzoOg+6 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline /sys/src/libc/9syscall/mkfile has a rather odd looking special case for the seek system call... it looks like if seek fails (returns -1) that the first two arguments (fd and offset) are overwritten with -1. What's going on here? The manual page doesn't hint at anything... Thanks. --nwf; --z8Ydz/NZAVzoOg+6 Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (GNU/Linux) iEYEARECAAYFAkj8MrUACgkQTeQabvr9Tc/bpQCfRK9x72hIRZNhKLmCED6bRyZ8 MDoAniB1gmzMcdzEhFzj0gW4eIzNmxHw =bO2W -----END PGP SIGNATURE----- --z8Ydz/NZAVzoOg+6--