From a5db9c3519fc07ddef6257ceb6771514fd0a26c5 Mon Sep 17 00:00:00 2001 From: Alexander Medvednikov Date: Thu, 27 Feb 2020 00:41:05 +0100 Subject: [PATCH] os: bring back write_bytes_at() --- vlib/os/os.v | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/vlib/os/os.v b/vlib/os/os.v index f10a40acb0..c326e07147 100644 --- a/vlib/os/os.v +++ b/vlib/os/os.v @@ -326,18 +326,15 @@ pub fn open_file(path string, mode string, options ...int) ?File { } } -/* pub fn (f mut File) write_bytes_at(data voidptr, size, pos int) { - $if linux { - } - $else { + //$if linux { + //} + //$else { C.fseek(f.cfile, pos, C.SEEK_SET) C.fwrite(data, 1, size, f.cfile) C.fseek(f.cfile, 0, C.SEEK_END) - } + //} } -*/ - pub fn (f mut File) flush() { if !f.opened {