aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2010-04-14 07:00:16 +0200
committerNguyễn Thái Ngọc Duy <pclouds@gmail.com>2010-09-10 18:40:27 +1000
commit4fc9774cb660ea99f90466c4253413447e23e2d0 (patch)
tree4cf60c70944e769fa01a5a1b993d82cfa5be9abe
parent63b80e79f69beec9a375f53d5cd8f20f55fb4746 (diff)
downloadbusybox-w32-4fc9774cb660ea99f90466c4253413447e23e2d0.tar.gz
busybox-w32-4fc9774cb660ea99f90466c4253413447e23e2d0.tar.bz2
busybox-w32-4fc9774cb660ea99f90466c4253413447e23e2d0.zip
win32: add realpath()
-rw-r--r--include/mingw.h2
-rw-r--r--win32/mingw.c6
2 files changed, 7 insertions, 1 deletions
diff --git a/include/mingw.h b/include/mingw.h
index 7fff1ad38..0eb97d516 100644
--- a/include/mingw.h
+++ b/include/mingw.h
@@ -132,7 +132,7 @@ int fdprintf(int fd, const char *format, ...);
132NOIMPL(clearenv,void); 132NOIMPL(clearenv,void);
133IMPL(mingw_getenv,char*,NULL,const char *name UNUSED_PARAM); 133IMPL(mingw_getenv,char*,NULL,const char *name UNUSED_PARAM);
134int mkstemp(char *template); 134int mkstemp(char *template);
135IMPL(realpath,char *,NULL,const char *path UNUSED_PARAM, char *resolved_path UNUSED_PARAM); 135char *realpath(const char *path, char *resolved_path);
136NOIMPL(setenv,const char *name UNUSED_PARAM, const char *value UNUSED_PARAM, int replace UNUSED_PARAM); 136NOIMPL(setenv,const char *name UNUSED_PARAM, const char *value UNUSED_PARAM, int replace UNUSED_PARAM);
137IMPL(unsetenv,void,,const char *env UNUSED_PARAM); 137IMPL(unsetenv,void,,const char *env UNUSED_PARAM);
138 138
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
370char *realpath(const char *path, char *resolved_path)
371{
372 /* FIXME: need normalization */
373 return strcpy(resolved_path, path);
374}