fseek.3s
来自「unix v7是最后一个广泛发布的研究型UNIX版本」· 3S 代码 · 共 59 行
3S
59 行
.TH FSEEK 3S .SH NAMEfseek, ftell, rewind \- reposition a stream.SH SYNOPSIS.B #include <stdio.h>.PP.B fseek(stream, offset, ptrname).br.SM.B FILE.B *stream;.br.B long offset;.PP.B long ftell(stream).br.SM.B FILE.B *stream;.PP.B rewind(stream).SH DESCRIPTION.I Fseeksets the position of the next input or outputoperation on the.IR stream .The new position is at the signed distance.I offsetbytesfrom the beginning, the current position, or the end of the file,according as .I ptrnamehas the value 0, 1, or 2..PP.I Fseekundoes any effects of.IR ungetc (3)..PP.I Ftellreturns the current value of the offset relative to the beginningof the file associated with the named.IR stream .It is measured in bytes on UNIX;on some other systems it is a magic cookie,and the only foolproof way to obtain an .I offsetfor.IR fseek ..PP.I Rewind(stream)is equivalent to.I "fseek(stream, 0L, 0).".SH "SEE ALSO"lseek(2),fopen(3).SH DIAGNOSTICS.I Fseekreturns \-1 for improper seeks.
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?