logo

oasis-root

Compiled tree of Oasis Linux based on own branch at <https://hacktivis.me/git/oasis/> git clone https://anongit.hacktivis.me/git/oasis-root.git

rewind.3p (2519B)


  1. '\" et
  2. .TH REWIND "3P" 2017 "IEEE/The Open Group" "POSIX Programmer's Manual"
  3. .\"
  4. .SH PROLOG
  5. This manual page is part of the POSIX Programmer's Manual.
  6. The Linux implementation of this interface may differ (consult
  7. the corresponding Linux manual page for details of Linux behavior),
  8. or the interface may not be implemented on Linux.
  9. .\"
  10. .SH NAME
  11. rewind
  12. \(em reset the file position indicator in a stream
  13. .SH SYNOPSIS
  14. .LP
  15. .nf
  16. #include <stdio.h>
  17. .P
  18. void rewind(FILE *\fIstream\fP);
  19. .fi
  20. .SH DESCRIPTION
  21. The functionality described on this reference page is aligned with the
  22. ISO\ C standard. Any conflict between the requirements described here and the
  23. ISO\ C standard is unintentional. This volume of POSIX.1\(hy2017 defers to the ISO\ C standard.
  24. .P
  25. The call:
  26. .sp
  27. .RS 4
  28. .nf
  29. rewind(stream)
  30. .fi
  31. .P
  32. .RE
  33. .P
  34. shall be equivalent to:
  35. .sp
  36. .RS 4
  37. .nf
  38. (void) fseek(stream, 0L, SEEK_SET)
  39. .fi
  40. .P
  41. .RE
  42. .P
  43. except that
  44. \fIrewind\fR()
  45. shall also clear the error indicator.
  46. .P
  47. Since
  48. \fIrewind\fR()
  49. does not return a value, an application wishing to detect errors should
  50. clear
  51. .IR errno ,
  52. then call
  53. \fIrewind\fR(),
  54. and if
  55. .IR errno
  56. is non-zero, assume an error has occurred.
  57. .SH "RETURN VALUE"
  58. The
  59. \fIrewind\fR()
  60. function shall not return a value.
  61. .SH ERRORS
  62. Refer to
  63. .IR "\fIfseek\fR\^(\|)"
  64. with the exception of
  65. .BR [EINVAL]
  66. which does not apply.
  67. .LP
  68. .IR "The following sections are informative."
  69. .SH EXAMPLES
  70. None.
  71. .SH "APPLICATION USAGE"
  72. None.
  73. .SH RATIONALE
  74. None.
  75. .SH "FUTURE DIRECTIONS"
  76. None.
  77. .SH "SEE ALSO"
  78. .IR "Section 2.5" ", " "Standard I/O Streams",
  79. .IR "\fIfseek\fR\^(\|)"
  80. .P
  81. The Base Definitions volume of POSIX.1\(hy2017,
  82. .IR "\fB<stdio.h>\fP"
  83. .\"
  84. .SH COPYRIGHT
  85. Portions of this text are reprinted and reproduced in electronic form
  86. from IEEE Std 1003.1-2017, Standard for Information Technology
  87. -- Portable Operating System Interface (POSIX), The Open Group Base
  88. Specifications Issue 7, 2018 Edition,
  89. Copyright (C) 2018 by the Institute of
  90. Electrical and Electronics Engineers, Inc and The Open Group.
  91. In the event of any discrepancy between this version and the original IEEE and
  92. The Open Group Standard, the original IEEE and The Open Group Standard
  93. is the referee document. The original Standard can be obtained online at
  94. http://www.opengroup.org/unix/online.html .
  95. .PP
  96. Any typographical or formatting errors that appear
  97. in this page are most likely
  98. to have been introduced during the conversion of the source files to
  99. man page format. To report such errors, see
  100. https://www.kernel.org/doc/man-pages/reporting_bugs.html .