projects
/
ghc-hetmet.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
6cfd484e741eaac24aa4578c82c983cb477cf706
[ghc-hetmet.git]
/
ghc
/
lib
/
cbits
/
flushFile.lc
1
%
2
% (c) The GRASP/AQUA Project, Glasgow University, 1994
3
%
4
\subsection[flushFile.lc]{hFlush Runtime Support}
5
6
\begin{code}
7
8
#include "rtsdefs.h"
9
#include "stgio.h"
10
11
StgInt
12
flushFile(fp)
13
StgForeignObj fp;
14
{
15
int rc;
16
17
while ((rc = fflush((FILE *) fp)) != 0) {
18
if (errno != EINTR) {
19
cvtErrno();
20
stdErrno();
21
return rc;
22
}
23
}
24
return 0;
25
}
26
27
\end{code}
28
29
30