From 6a26cd6621b5f0b70177b0d17ed433b5669f1314 Mon Sep 17 00:00:00 2001 From: oy Date: Thu, 7 Oct 2010 23:51:07 +0200 Subject: fixed various problems with the file dialog in the editor --- src/base/system.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'src/base/system.c') diff --git a/src/base/system.c b/src/base/system.c index 25e89896..6a70452f 100644 --- a/src/base/system.c +++ b/src/base/system.c @@ -997,7 +997,7 @@ int fs_chdir(const char *path) return 1; } -void fs_parent_dir(char *path) +int fs_parent_dir(char *path) { char *parent = 0; for(; *path; ++path) @@ -1007,7 +1007,11 @@ void fs_parent_dir(char *path) } if(parent) + { *parent = 0; + return 0; + } + return 1; } void swap_endian(void *data, unsigned elem_size, unsigned num) -- cgit 1.4.1