diff options
-rw-r--r-- | lib/std/syncio.nim | 2 | ||||
-rw-r--r-- | lib/system/ansi_c.nim | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/syncio.nim b/lib/std/syncio.nim index dadad9791..d406c254f 100644 --- a/lib/std/syncio.nim +++ b/lib/std/syncio.nim @@ -105,7 +105,7 @@ proc c_feof(f: File): cint {. importc: "feof", header: "<stdio.h>".} when not declared(c_fwrite): - proc c_fwrite(buf: pointer, size, n: csize_t, f: File): cint {. + proc c_fwrite(buf: pointer, size, n: csize_t, f: File): csize_t {. importc: "fwrite", header: "<stdio.h>".} # C routine that is used here: diff --git a/lib/system/ansi_c.nim b/lib/system/ansi_c.nim index ae4b90504..a8a4bd767 100644 --- a/lib/system/ansi_c.nim +++ b/lib/system/ansi_c.nim @@ -211,7 +211,7 @@ else: proc c_realloc*(p: pointer, newsize: csize_t): pointer {. importc: "realloc", header: "<stdlib.h>".} -proc c_fwrite*(buf: pointer, size, n: csize_t, f: CFilePtr): cint {. +proc c_fwrite*(buf: pointer, size, n: csize_t, f: CFilePtr): csize_t {. importc: "fwrite", header: "<stdio.h>".} proc c_fflush*(f: CFilePtr): cint {. |