📄 skiprec.3
字号:
.\" Copyright (c) 1987-1990 Entropic Speech, Inc..\" Copyright (c) 1990-1997 Entropic Research Laboratory, Inc. All rights reserved..\" @(#)skiprec.3 1.6 30 Sep 1997 ESI/ERL.ds ]W (c) 1997 Entropic Research Laboratory, Inc..TH SKIPREC 3\-ESPSu 30 Sep 1997.SH NAMEskiprec \- skip fixed-length records in a filefea_skiprec \- skip records in a file.SH SYNOPSIS.nf.ft Bvoidskiprec(stream, nrec, size)FILE *stream;long nrec;int size;voidfea_skiprec(stream, nrecs, hdr)FILE *stream;long nrecs;struct header *hdr;.ft.fi.SH DESCRIPTION.PP.I skiprecchanges position in a binary file.It skips forward.I nrecrecords, each containing.I sizebytes.It first tries to accomplish this with a disk seek operation.If the seek would change the position to beyond the end of the file,the position is left at the end of the file.If this fails (for instance,.I streammay be a pipe) and.I nrecis nonnegative, it skips forward by reading the file and discarding the output..PP.I fea_skiprecchanges position in a file described by the ESPS header structureindicated by.I hdr.When the file is an ordinary FEA file.RI ( FEA (5\-ESPS)),the effect is simply that of.LP.RS.nf.if t .ft Iskiprec(stream, nrecs, size_rec(hdr));.if t .ft P.fi.RE.LPHowever,.I fea_skiprecalso works when.RI * hdris a surrogate header created by.IR read_header (3\-ESPS)upon reading a NIST.I Spherefile or an Entropic.I Esignalfile.In those cases.I fea_skipreccalls the appropriate.I Sphereor.I Esignalroutine.It can thus handle certain formatsthat do not store records in fixed-size chunks.Examples are.I Spherevariable-rate compressed formats and the.I EsignalASCII representation.Being more general than the combination of.I skiprecwith.IR size_rec (3\-ESPS),the function.I fea_skiprecis to be preferred..SH DIAGNOSTICSIf a seek error occurs and.I nrecis negative,.I skiprecprints an error message on the error output and exits.An assertion failure.RI ( spsassert (3\-ESPS))occurs if.I skiprecis called with a NULL argument.I streamor a negative argument.I siz,or if.I fea_skiprecis called with a NULL argument.I streamor a NULL argument.I hdr..SH SEE ALSO.IR read_header (3\-ESPS),.IR size_rec (3\-ESPSu),.IR spsassert (3\-ESPS),.br.IR FEA (5\-ESPS).SH AUTHOR
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -