1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

* missing/os2.c (chdir, getcwd):

use _chdir2 and _getcwd2 supporting multiple drives in OS/2 with EMX.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@5534 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
siena 2004-01-21 16:23:07 +00:00
parent a9f5c042ef
commit d0149b9e21
2 changed files with 28 additions and 0 deletions

View file

@ -1,3 +1,8 @@
Thu Jan 22 01:12:12 2004 Siena. <siena@faculty.chiba-u.jp>
* missing/os2.c (chdir, getcwd):
use _chdir2 and _getcwd2 supporting multiple drives in OS/2 with EMX.
Thu Jan 22 00:33:52 2004 Siena. <siena@faculty.chiba-u.jp>
* configure.in: check availability of link(). [ruby-dev:22237]

View file

@ -25,6 +25,29 @@ link(char *from, char *to)
}
#endif
#if defined(EMX_REPLACE_GETCWD) && (EMX_REPLACE_GETCWD) \
|| defined(EMX_REPLACE_CHDIR) && (EMX_REPLACE_CHDIR)
#include <unistd.h>
#if defined(EMX_REPLACE_GETCWD) && (EMX_REPLACE_GETCWD)
/* to handle the drive letter and DBCS characters within a given path */
char *
getcwd(char *path, size_t len)
{
return _getcwd2(path, (int)len);
}
#endif
#if defined(EMX_REPLACE_CHDIR) && (EMX_REPLACE_CHDIR)
/* to handle the drive letter and DBCS characters within a given path */
int
chdir(__const__ char *path)
{
return _chdir2(path);
}
#endif
#endif
typedef char* CHARP;
int