'\" t .\" Copyright (c) 1980, 1991 Regents of the University of California. .\" All rights reserved. .\" .\" Redistribution and use in source and binary forms, with or without .\" modification, are permitted provided that the following conditions .\" are met: .\" 1. Redistributions of source code must retain the above copyright .\" notice, this list of conditions and the following disclaimer. .\" 2. Redistributions in binary form must reproduce the above copyright .\" notice, this list of conditions and the following disclaimer in the .\" documentation and/or other materials provided with the distribution. .\" 3. All advertising materials mentioning features or use of this software .\" must display the following acknowledgement: .\" This product includes software developed by the University of .\" California, Berkeley and its contributors. .\" 4. Neither the name of the University nor the names of its contributors .\" may be used to endorse or promote products derived from this software .\" without specific prior written permission. .\" .\" THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND .\" ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE .\" IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE .\" ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE .\" FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL .\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS .\" OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) .\" HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" .\" @(#)lseek.2 6.5 (Berkeley) 3/10/91 .\" .\" Modified Fri Jul 23 22:17:00 1993 by Rik Faith .\" Modified 10 June 1995 by Andries Brouwer .\" Modified Thu Oct 31 15:18:33 1996 by Eric S. Raymond .\" Modified Sat Jan 17 13:00:32 MET 1998 by Michael Haardt .\" .TH LSEEK 2 "Januari 17, 1998" "Linux" "Systeem aanroepen" .SH NAAM lseek \- herplaats lees/schrijf bestand-positie .SH OVERZICHT .B #include .br .B #include .sp .BI "off_t lseek(int " bes_ind ", off_t " positie ", int " vanaf ); .SH BESCHRIJVING De .B lseek functie herplaatst de positie van de bestandindicator .I bes_ind naar het argument .I positie volgens de aanwijzing .I vanaf als volgt: .TP .B SEEK_SET De positie wordt naar .I positie bytes gezet. .TP .B SEEK_CUR De positie wordt naar de huidige plaats plus .I positie bytes gezet. .TP .B SEEK_END De positie wordt naar de lengte van het bestand plus .I positie bytes gezet. .PP De .B lseek functie status toe dat de bestand positie verder dan het einde van het bestaande einde-van-bestand van het bestand wordt gezet. Als gegevens later op deze positie worden geschreven, geven navolgende lees opdrachten in het gat ge-Nulde bytes terug (totdat er daadwerkelijk gegevens in het gat worden geschreven). .SH "TERUGGEEF WAARDE" Bij geslaagde afronding geeft .B lseek de opgeleverde plaats zoals gemeten in bytes van het begin van het bestand, terug. Anders wordt een waarde van (off_t)\-1 teruggegeven, en .I errno wordt gezet om de fout duidelijk te maken. .SH FOUTEN .TP .B EBADF {slechte*} .I bes_ind is geen open bestandindicator. .TP .B ESPIPE .I bes_ind hoort bij een pijp, een socket, of een FIFO. .TP .B EINVAL {ongeldig} .I Vanaf is geen juiste waarde. .SH "VOLDOET AAN" SVr4, POSIX, BSD 4.3 .SH BEPERKINGEN Sommige apparaten zijn niet in status tot zoeken, en POSIX bepaald niet welke apparaten het moeten ondersteunen. Linux-eigen beperkingen: \fBlseek\fP op een tty apparaat gebruiken geeft \fBESPIPE\fP terug. Andere systemen geven het aantal geschreven letters, met gebruik van SEEK_SET om de teller te zetten. Sommige apparaten, zoals \fB/dev/null\fP veroorzaken de fout \fBESPIPE\fP niet, maar geven een pointer terug met onbepaalde waarde. .SH OPMERKINGEN Het gebruik van .I vanaf in dit document is niet goed Engels {zie Engelse manpage}, maar volgehouden voor historische redenen. Bij het omzetten van oude code, vervang de waarde voor \fIvanaf\fP met de volgende macro's: .PP .TS c c l l. oud nieuw 0 SEEK_SET 1 SEEK_CUR 2 SEEK_END L_SET SEEK_SET L_INCR SEEK_CUR L_XTND SEEK_END .TE .PP SVR1-3 geeft \fB"long"\fP terug in plaats van \fB"off_t"\fP, BSD geeft \fB"int"\fP terug. .SH "ZIE" .BR dup "(2) {kopieer}," .BR open "(2) {open}," .BR fseek "(3) {zoek}" .\" Translated Wed Nov 8 18:43:59 CET 2000 by Jos Boersema .\" .SH VERTALING Dit is een handleiding uit \fBmanpages-dev 1.29\fR. .PP Alles wat tussen `\fB{\fR'..`\fB}\fR' staat is \fBaanvullende vertaling\fR, en hoort \fBniet\fR bij de originele handleiding. Email naar . .\"Vertaling Jos Boersema $Id: lseek.2,v 1.1 2003/04/28 18:43:34 bokkie Exp $