From 45ba8188d181c4b9316366f89fc955956c26e502 Mon Sep 17 00:00:00 2001 From: dec05eba Date: Mon, 27 Jul 2020 05:46:26 +0200 Subject: Use current directory (.) for file directory if relative --- src/std/file.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src') diff --git a/src/std/file.c b/src/std/file.c index bd0d8cc..d61e871 100644 --- a/src/std/file.c +++ b/src/std/file.c @@ -268,7 +268,7 @@ BufferView file_get_parent_directory(BufferView filepath) { if(filepath.data[i] == '/') return create_buffer_view(filepath.data, i); } - return create_buffer_view(filepath.data, 0); + return create_buffer_view(".", 1); } BufferView file_get_name(BufferView filepath) { -- cgit v1.2.3