From 51ecf18f6ce5b9e06ec61423548270b4746f379d Mon Sep 17 00:00:00 2001 From: bonmas14 Date: Mon, 29 Sep 2025 19:58:12 +0300 Subject: Added zlib --- src/cyn_file_win.c | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) create mode 100644 src/cyn_file_win.c (limited to 'src/cyn_file_win.c') diff --git a/src/cyn_file_win.c b/src/cyn_file_win.c new file mode 100644 index 0000000..1ded1de --- /dev/null +++ b/src/cyn_file_win.c @@ -0,0 +1,37 @@ +File_Handle *cyn_file_open(String path, File_Status *status) { + wchar *final_path; + Allocator talloc; + + talloc = un_alloc_temp_get(); + + final_path = un_wstring_from_string(path, talloc); + + if (path.size > MAX_PATH) { + if (status != NULL) *status = CYN_FILE_ERROR_MAX_PATH; + return NULL; + } + + if (final_path == NULL) { + if (status != NULL) *status = CYN_FILE_ERROR_NULL_FILENAME; + return NULL; // @todo status + } + + //CreateFileW(); + + if (status != NULL) *status = CYN_FILE_ERROR; + + return NULL; +} + +/* + +HANDLE CreateFileW( + LPCWSTR lpFileName, + DWORD dwDesiredAccess, + DWORD dwShareMode, + NULL, + DWORD dwCreationDisposition, + DWORD dwFlagsAndAttributes, + NULL +); +*/ -- cgit v1.2.3-70-g09d2