summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-03-30 09:32:56 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>1998-03-30 09:32:56 +0000
commit1dd17757b547dbc056faa42e13fd3e1fd711a608 (patch)
treea5be8dbddace6615325aa7034305eea807ff6086
parent1234770ca21f8bd9586b6c932fdb2cd2b0b2271b (diff)
gw32 b19 patch
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/v1_1r@146 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--ChangeLog8
-rw-r--r--Makefile.in9
-rw-r--r--dir.c2
-rw-r--r--dln.c2
-rw-r--r--ext/etc/etc.c2
-rw-r--r--ext/extmk.rb.in2
-rw-r--r--ext/socket/extconf.rb2
-rw-r--r--ext/socket/socket.c2
-rw-r--r--file.c4
-rw-r--r--instruby.rb1
-rw-r--r--io.c4
-rw-r--r--string.c12
12 files changed, 32 insertions, 18 deletions
diff --git a/ChangeLog b/ChangeLog
index cf235b4db5..9db15932b7 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+Mon Mar 30 14:07:07 1998 Yukihiro Matsumoto <matz@netlab.co.jp>
+
+ * string.c (str_intern): typo in error message.
+
+Mon Mar 30 14:06:19 1998 Tadayoshi Funaba <tadf@kt.rim.or.jp>
+
+ * string.c (str_capitalize_bang): did not check string modification.
+
Sat Mar 28 20:40:12 1998 Yukihiro Matsumoto <matz@netlab.co.jp>
* experimental release 1.1b9_06.
diff --git a/Makefile.in b/Makefile.in
index a237ef149d..bafabdcf55 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -70,11 +70,11 @@ all: miniruby$(binsuffix) rbconfig.rb
miniruby$(binsuffix): $(OBJS) $(MAINOBJ) dmyext.o
@rm -f $@
- $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) $(OBJS) dmyext.o $(LIBS) -o miniruby
+ $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) $(OBJS) dmyext.o $(LIBS) -o $@
ruby$(binsuffix): $(LIBRUBY) $(MAINOBJ) $(EXTOBJS)
@rm -f $@
- $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) $(EXTOBJS) $(LIBRUBY) $(LIBS) -o ruby
+ $(PURIFY) $(CC) $(LDFLAGS) $(MAINOBJ) $(EXTOBJS) $(LIBRUBY) $(LIBS) -o $@
$(LIBRUBY): $(OBJS) dmyext.o
@AR@ rcu $(LIBRUBY) $(OBJS) dmyext.o
@@ -85,7 +85,10 @@ install: rbconfig.rb
clean:; @rm -f $(OBJS) $(LIBRUBY) $(MAINOBJ) rbconfig.rb
@rm -f ext/extinit.c ext/extinit.o dmyext.o
- @if test -f ./miniruby; then cd ext; ../miniruby ./extmk.rb clean; fi
+ @if test -f ./miniruby$(binsuffix); then \
+ cd ext; \
+ ../miniruby$(binsuffix) ./extmk.rb clean; \
+ fi
realclean: clean
@rm -f Makefile ext/extmk.rb ext/config.cache
diff --git a/dir.c b/dir.c
index 3d4ea58fa2..a0186f0221 100644
--- a/dir.c
+++ b/dir.c
@@ -215,7 +215,7 @@ static VALUE
dir_s_chroot(dir, path)
VALUE dir, path;
{
-#if !defined(DJGPP) && !defined(__CYGWIN32__) && !defined(NT) && !defined(__human68k__)
+#if !defined(DJGPP) && !defined(NT) && !defined(__human68k__)
rb_secure(2);
Check_SafeStr(path);
diff --git a/dln.c b/dln.c
index 5d4ed14800..ed20087b6a 100644
--- a/dln.c
+++ b/dln.c
@@ -1350,7 +1350,7 @@ dln_find_exe(fname, path)
if (!path)
path = getenv("path");
if (!path)
- path = "/usr/local/bin;/usr/usb;/usr/bin;/bin;.";
+ path = "/usr/local/bin;/usr/ucb;/usr/bin;/bin;.";
#else
if (!path) path = getenv("PATH");
if (!path) path = "/usr/local/bin:/usr/ucb:/usr/bin:/bin:.";
diff --git a/ext/etc/etc.c b/ext/etc/etc.c
index 20cd9295ed..203df635c1 100644
--- a/ext/etc/etc.c
+++ b/ext/etc/etc.c
@@ -123,7 +123,7 @@ static VALUE
etc_passwd(obj)
VALUE obj;
{
-#if defined(HAVE_GETPWENT) && !defined(__CYGWIN32__)
+#if defined(HAVE_GETPWENT)
struct passwd *pw;
if (iterator_p()) {
diff --git a/ext/extmk.rb.in b/ext/extmk.rb.in
index f8f69973e9..9c6f3f50e2 100644
--- a/ext/extmk.rb.in
+++ b/ext/extmk.rb.in
@@ -471,7 +471,7 @@ else
Dir.chdir ".."
if older("ruby@binsuffix@", "miniruby@binsuffix@")
`rm -f ruby@binsuffix@`
- `cp miniruby@binsuffix@ ruby@binsuffix@`
+ system("make ruby@binsuffix@")
end
end
diff --git a/ext/socket/extconf.rb b/ext/socket/extconf.rb
index f719723864..bbda95cf83 100644
--- a/ext/socket/extconf.rb
+++ b/ext/socket/extconf.rb
@@ -4,7 +4,7 @@ when /mswin32/
test_func = "WSACleanup"
have_library("wsock32", "WSACleanup")
when /cygwin32/
- test_func = "cygwin32_socket"
+ test_func = "socket"
else
test_func = "socket"
have_library("socket", "socket")
diff --git a/ext/socket/socket.c b/ext/socket/socket.c
index 1b87ae9146..d45db8b818 100644
--- a/ext/socket/socket.c
+++ b/ext/socket/socket.c
@@ -1137,7 +1137,7 @@ static VALUE
sock_s_socketpair(class, domain, type, protocol)
VALUE class, domain, type, protocol;
{
-#if !defined(__CYGWIN32__) && !defined(NT)
+#if !defined(NT)
int fd;
int d, t, sp[2];
diff --git a/file.c b/file.c
index 56a139f7b2..bacb7aaa30 100644
--- a/file.c
+++ b/file.c
@@ -929,7 +929,7 @@ file_chmod(obj, vmode)
mode = NUM2INT(vmode);
GetOpenFile(obj, fptr);
-#if defined(DJGPP) || defined(__CYGWIN32__) || defined(NT)
+#if defined(DJGPP) || defined(NT)
if (chmod(fptr->path, mode) == -1)
rb_sys_fail(fptr->path);
#else
@@ -1162,7 +1162,7 @@ file_s_umask(argc, argv)
int omask = 0;
if (argc == 0) {
- int omask = umask(0);
+ omask = umask(0);
umask(omask);
}
else if (argc == 1) {
diff --git a/instruby.rb b/instruby.rb
index 47b7fcad9a..1fb1fe30bd 100644
--- a/instruby.rb
+++ b/instruby.rb
@@ -20,6 +20,7 @@ mandir = CONFIG["mandir"] + "/man1"
File.install "ruby#{binsuffix}",
"#{bindir}/#{ruby_install_name}#{binsuffix}", 0755, TRUE
+File.install "rubygw32.dll", "#{bindir}/rubygw32.dll", 0755, TRUE
File.makedirs libdir, TRUE
Dir.chdir "ext"
system "../miniruby#{binsuffix} extmk.rb install"
diff --git a/io.c b/io.c
index 7e8310a714..b187bfec31 100644
--- a/io.c
+++ b/io.c
@@ -160,7 +160,7 @@ io_write(io, str)
#ifdef __human68k__
{
register UCHAR *ptr = RSTRING(str)->ptr;
- n = (int) RSTRING(str)->len;
+ n = (int)RSTRING(str)->len;
while (--n >= 0)
if (fputc(*ptr++, f) == EOF)
rb_sys_fail(fptr->path);
@@ -809,7 +809,7 @@ io_binmode(io)
#ifdef __human68k__
if (fptr->f)
fmode(fptr->f, _IOBIN);
- if (fptr->f2);
+ if (fptr->f2)
fmode(fptr->f2, _IOBIN);
#else
if (fptr->f && setmode(fileno(fptr->f), O_BINARY) == -1)
diff --git a/string.c b/string.c
index e60088fd88..59e4024bbf 100644
--- a/string.c
+++ b/string.c
@@ -1610,8 +1610,10 @@ str_capitalize_bang(str)
str_modify(str);
s = RSTRING(str)->ptr; send = s + RSTRING(str)->len;
- if (islower(*s))
+ if (islower(*s)) {
*s = toupper(*s);
+ modify = 1;
+ }
while (++s < send) {
if (ismbchar(*s)) {
s++;
@@ -1867,10 +1869,10 @@ str_delete_bang(str1, str2)
s = t = RSTRING(str1)->ptr;
send = s + RSTRING(str1)->len;
while (s < send) {
- if (!squeez[*s & 0xff]) {
- *t++ = *s;
+ if (squeez[*s & 0xff])
modify = 1;
- }
+ else
+ *t++ = *s;
s++;
}
*t = '\0';
@@ -2469,7 +2471,7 @@ str_intern(str)
ID id;
if (strlen(RSTRING(str)->ptr) != RSTRING(str)->len)
- ArgError("string contains `\0'");
+ ArgError("string contains `\\0'");
id = rb_intern(RSTRING(str)->ptr);
return INT2FIX(id);
}