diff options
author | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2010-04-14 07:00:16 +0200 |
---|---|---|
committer | Nguyễn Thái Ngọc Duy <pclouds@gmail.com> | 2010-04-20 19:14:05 +0200 |
commit | ca46d5097f6124489fbd3d6b45290c2c9b643831 (patch) | |
tree | 891a8a054e8e57447a88475e9df18c4dd0835996 | |
parent | fda663db764bf427adfd5564a343cac1df388667 (diff) | |
download | busybox-w32-ca46d5097f6124489fbd3d6b45290c2c9b643831.tar.gz busybox-w32-ca46d5097f6124489fbd3d6b45290c2c9b643831.tar.bz2 busybox-w32-ca46d5097f6124489fbd3d6b45290c2c9b643831.zip |
win32: add realpath()
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com>
-rw-r--r-- | include/mingw.h | 2 | ||||
-rw-r--r-- | win32/mingw.c | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/include/mingw.h b/include/mingw.h index 9267adf7a..404360d29 100644 --- a/include/mingw.h +++ b/include/mingw.h | |||
@@ -133,7 +133,7 @@ int fdprintf(int fd, const char *format, ...); | |||
133 | NOIMPL(clearenv,void); | 133 | NOIMPL(clearenv,void); |
134 | IMPL(mingw_getenv,char*,NULL,const char *name UNUSED_PARAM); | 134 | IMPL(mingw_getenv,char*,NULL,const char *name UNUSED_PARAM); |
135 | int mkstemp(char *template); | 135 | int mkstemp(char *template); |
136 | IMPL(realpath,char *,NULL,const char *path UNUSED_PARAM, char *resolved_path UNUSED_PARAM); | 136 | char *realpath(const char *path, char *resolved_path); |
137 | NOIMPL(setenv,const char *name UNUSED_PARAM, const char *value UNUSED_PARAM, int replace UNUSED_PARAM); | 137 | NOIMPL(setenv,const char *name UNUSED_PARAM, const char *value UNUSED_PARAM, int replace UNUSED_PARAM); |
138 | IMPL(unsetenv,void,,const char *env UNUSED_PARAM); | 138 | IMPL(unsetenv,void,,const char *env UNUSED_PARAM); |
139 | 139 | ||
diff --git a/win32/mingw.c b/win32/mingw.c index 937e9422c..b879bfbae 100644 --- a/win32/mingw.c +++ b/win32/mingw.c | |||
@@ -366,3 +366,9 @@ char *strsep(char **stringp, const char *delim) | |||
366 | *stringp = NULL; | 366 | *stringp = NULL; |
367 | return old_stringp; | 367 | return old_stringp; |
368 | } | 368 | } |
369 | |||
370 | char *realpath(const char *path, char *resolved_path) | ||
371 | { | ||
372 | /* FIXME: need normalization */ | ||
373 | return strcpy(resolved_path, path); | ||
374 | } | ||