Mono Class Library: Mono.Unix.Native.Stdlib Overview | Members

Mono.Unix.Native.Stdlib.fflush Method

Flush a FILE stream. [Edit]

public static int fflush (IntPtr stream)

Parameters

stream
The FILE stream to flush. [Edit]

Returns

Upon successful completion 0 is returned. Otherwise, Stdlib.EOF is returned and the global variable errno is set to indicate the error.
Usage

The following errors are specified:

ErrorDetails
Errno.EBADFThe stream argument is not an open stream, or not a stream open for writing.

The function fflush may also fail and set errno for any of the errors specified for Syscall.write(2).

[Edit]

Remarks

The function fflush() forces a write of all buffered data for the given output or update stream via the stream's underlying write function. The open status of the stream is unaffected.

If the stream argument is IntPtr.Zero, fflush() flushes all open output streams.

[Edit]

Requirements

Namespace: Mono.Unix.Native
Assembly: Mono.Posix (in Mono.Posix.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0