summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoreban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-01-18 11:59:43 +0000
committereban <eban@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2004-01-18 11:59:43 +0000
commit9510329642ec8365926c77a47c23a8128e43b1eb (patch)
treee5164c2387505468446d6fa09f0854df18eda159
parent6fe3960debbb41aeb5f9fcb27213cb957c45bbc1 (diff)
downloadruby-9510329642ec8365926c77a47c23a8128e43b1eb.tar.gz
ruby-9510329642ec8365926c77a47c23a8128e43b1eb.tar.xz
ruby-9510329642ec8365926c77a47c23a8128e43b1eb.zip
* ruby.c: use translate_char() on Cygwin.
git-svn-id: http://svn.ruby-lang.org/repos/ruby/branches/ruby_1_8@5491 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog4
-rw-r--r--ruby.c6
2 files changed, 7 insertions, 3 deletions
diff --git a/ChangeLog b/ChangeLog
index c391e9fba..095232fe4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+Sun Jan 18 20:47:35 2004 WATANABE Hirofumi <eban@ruby-lang.org>
+
+ * ruby.c: use translate_char() on Cygwin.
+
Sun Jan 18 02:33:26 2004 WATANABE Hirofumi <eban@ruby-lang.org>
* defines.h (_WIN32): undef _WIN32 on Cygwin before defining DOSISH.
diff --git a/ruby.c b/ruby.c
index 2f0dceb69..afe1e71ae 100644
--- a/ruby.c
+++ b/ruby.c
@@ -212,7 +212,7 @@ ruby_incpush(path)
#define LOAD_RELATIVE 1
#endif
-#ifdef DOSISH
+#if defined DOSISH || defined __CYGWIN__
static inline void translate_char _((char *, int, int));
static inline void
@@ -260,7 +260,7 @@ ruby_init_loadpath()
#endif
libpath[FILENAME_MAX] = '\0';
-#ifdef DOSISH
+#if defined DOSISH || defined __CYGWIN__
translate_char(libpath, '\\', '/');
#endif
p = strrchr(libpath, '/');
@@ -755,7 +755,7 @@ proc_options(argc, argv)
script = ruby_sourcefile = rb_source_filename(script);
script_node = NEW_NEWLINE(0);
}
-#ifdef DOSISH
+#if defined DOSISH || defined __CYGWIN__
translate_char(script, '\\', '/');
#endif
argc--; argv++;