aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authormatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-01-04 14:20:35 +0000
committermatz <matz@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2002-01-04 14:20:35 +0000
commit1d6e0f8281a3b00829f8360c9fcf58b69788d401 (patch)
tree4026a4e1e49de6e28ee6c420b22d89328f7efb09
parent566aa6625327e534c4941f2c2b6ca6c4f06162f3 (diff)
downloadruby-1d6e0f8281a3b00829f8360c9fcf58b69788d401.tar.gz
forgot to commit everything bug ChangeLog
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_6@1960 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--bignum.c2
-rw-r--r--configure.in1
-rw-r--r--defines.h14
-rw-r--r--doc/NEWS2
-rw-r--r--io.c5
-rw-r--r--lib/pstore.rb4
-rw-r--r--lib/weakref.rb6
-rw-r--r--misc/ruby-mode.el4
-rw-r--r--parse.y2
-rw-r--r--process.c5
-rw-r--r--regex.c28
-rw-r--r--regex.h1
12 files changed, 23 insertions, 51 deletions
diff --git a/bignum.c b/bignum.c
index 2c70b4b8f0..ee119f2d1d 100644
--- a/bignum.c
+++ b/bignum.c
@@ -252,8 +252,8 @@ rb_cstr2inum(str, base)
if (*end == '_') goto bigparse;
if (badcheck) {
- if (end == str) goto bad; /* no number */
while (*end && ISSPACE(*end)) end++;
+ if (end == str) goto bad; /* no number */
if (*end) { /* trailing garbage */
bad:
rb_raise(rb_eArgError, "invalid value for Integer: \"%s\"", s);
diff --git a/configure.in b/configure.in
index e007e4caf9..bce15f0001 100644
--- a/configure.in
+++ b/configure.in
@@ -273,7 +273,6 @@ dnl Checks for library functions.
AC_TYPE_GETGROUPS
AC_TYPE_SIGNAL
AC_FUNC_ALLOCA
-AC_FUNC_VFORK
AC_FUNC_MEMCMP
AC_REPLACE_FUNCS(dup2 memmove mkdir strcasecmp strncasecmp strerror strftime\
strchr strstr strtoul crypt flock vsnprintf\
diff --git a/defines.h b/defines.h
index e4ae64839e..f566332334 100644
--- a/defines.h
+++ b/defines.h
@@ -49,11 +49,15 @@
#define EXTERN extern
#endif
-#ifdef sparc
-#define FLUSH_REGISTER_WINDOWS asm("ta 3")
-#else
-#define FLUSH_REGISTER_WINDOWS /* empty */
-#endif
+#if defined(sparc) || defined(__sparc__)
+# if defined(linux) || defined(__linux__)
+#define FLUSH_REGISTER_WINDOWS asm("ta 0x83")
+# else /* Solaris, not sparc linux */
+#define FLUSH_REGISTER_WINDOWS asm("ta 0x03")
+# endif /* trap always to flush register windows if we are on a Sparc system */
+#else /* Not a sparc, so */
+#define FLUSH_REGISTER_WINDOWS /* empty -- nothing to do here */
+#endif
#if defined(MSDOS) || defined(_WIN32) || defined(__human68k__) || defined(__EMX__)
#define DOSISH 1
diff --git a/doc/NEWS b/doc/NEWS
index cf7b0e3b1d..95ba1f10b7 100644
--- a/doc/NEWS
+++ b/doc/NEWS
@@ -1,4 +1,4 @@
-Summary of the changes since 1.6.4:
+Summary of the changes since 1.6.5:
: Syslog module
diff --git a/io.c b/io.c
index 1a6d9d4d45..d5fcbeb2c9 100644
--- a/io.c
+++ b/io.c
@@ -51,9 +51,6 @@ struct timeval {
};
#endif
#endif
-#ifdef HAVE_VFORK_H
-#include <vfork.h>
-#endif
#include <sys/stat.h>
@@ -1600,7 +1597,7 @@ pipe_open(pname, mode)
}
retry:
- switch (pid = (doexec?vfork():fork())) {
+ switch ((pid = fork())) {
case 0: /* child */
if (modef & FMODE_READABLE) {
close(pr[0]);
diff --git a/lib/pstore.rb b/lib/pstore.rb
index 138e9aa520..fa82a48052 100644
--- a/lib/pstore.rb
+++ b/lib/pstore.rb
@@ -85,11 +85,11 @@ class PStore
value = nil
backup = @filename+"~"
if File::exist?(@filename)
- file = File::open(@filename, "r+")
+ file = File::open(@filename, "rb+")
orig = true
else
@table = {}
- file = File::open(@filename, "w+")
+ file = File::open(@filename, "wb+")
Marshal::dump(@table, file)
end
file.flock(File::LOCK_EX)
diff --git a/lib/weakref.rb b/lib/weakref.rb
index 459f69f924..6861fde5f5 100644
--- a/lib/weakref.rb
+++ b/lib/weakref.rb
@@ -60,7 +60,11 @@ class WeakRef<Delegator
unless ID_MAP[@__id]
raise RefError, "Illegal Reference - probably recycled", caller(2)
end
- ObjectSpace._id2ref(@__id)
+ begin
+ ObjectSpace._id2ref(@__id)
+ rescue RangeError
+ raise RefError, "Illegal Reference - probably recycled", caller(2)
+ end
end
def weakref_alive?
diff --git a/misc/ruby-mode.el b/misc/ruby-mode.el
index 437999dfdc..b03a1c92c3 100644
--- a/misc/ruby-mode.el
+++ b/misc/ruby-mode.el
@@ -673,8 +673,8 @@ An end of a defun is found by moving forward from the beginning of one."
(add-hook 'ruby-mode-hook
'(lambda ()
- (make-local-variable 'font-lock-syntactic-keywords)
- (setq font-lock-syntactic-keywords
+ (make-local-variable 'ruby-font-lock-syntactic-keywords)
+ (setq ruby-font-lock-syntactic-keywords
'(
;; #{ }, #$hoge, #@foo are not comments
("\\(#\\)[{$@]" 1 (1 . nil))
diff --git a/parse.y b/parse.y
index aa41474fce..e223b43c45 100644
--- a/parse.y
+++ b/parse.y
@@ -1974,7 +1974,7 @@ yycompile(f, line)
ruby__end__seen = 0;
ruby_eval_tree = 0;
heredoc_end = 0;
- ruby_sourcefile = f;
+ ruby_sourcefile = strdup(f);
ruby_in_compile = 1;
n = yyparse();
ruby_debug_lines = 0;
diff --git a/process.c b/process.c
index 618bbc974d..e10c0d7096 100644
--- a/process.c
+++ b/process.c
@@ -40,9 +40,6 @@ struct timeval rb_time_interval _((VALUE));
#ifdef HAVE_GETPRIORITY
# include <sys/resource.h>
#endif
-#ifdef HAVE_VFORK_H
-#include <vfork.h>
-#endif
#include "st.h"
#ifdef __EMX__
@@ -727,7 +724,7 @@ rb_f_system(argc, argv)
Check_SafeStr(argv[i]);
}
retry:
- switch (pid = vfork()) {
+ switch (pid = fork()) {
case 0:
if (argc == 1 && prog == 0) {
rb_proc_exec(RSTRING(argv[0])->ptr);
diff --git a/regex.c b/regex.c
index ed6a41880d..04c56c1264 100644
--- a/regex.c
+++ b/regex.c
@@ -1264,7 +1264,6 @@ re_compile_pattern(pattern, size, bufp)
bufp->fastmap_accurate = 0;
bufp->must = 0;
bufp->must_skip = 0;
- bufp->stclass = 0;
/* Initialize the syntax table. */
init_syntax_once();
@@ -2393,9 +2392,6 @@ re_compile_pattern(pattern, size, bufp)
p0 += mcnt+1;
mcnt = EXTRACT_UNSIGNED_AND_INCR(p0);
p0 += 8*mcnt;
- if (*p0 == maybe_finalize_jump) {
- bufp->stclass = laststart;
- }
}
}
}
@@ -3288,30 +3284,6 @@ re_search(bufp, string, size, startpos, range, regs)
startpos++;
}
}
- else if (fastmap && (bufp->stclass)) {
- register unsigned char *p;
- unsigned long c;
- int irange = range;
-
- p = (unsigned char*)string+startpos;
- while (range > 0) {
- c = *p++;
- if (ismbchar(c) && fastmap[c] != 2) {
- MBC2WC(c, p);
- }
- else if (MAY_TRANSLATE())
- c = translate[c];
- if (*bufp->stclass == charset) {
- if (!is_in_list(c, bufp->stclass+1)) break;
- }
- else {
- if (is_in_list(c, bufp->stclass+1)) break;
- }
- range--;
- if (c > 256) range--;
- }
- startpos += irange - range;
- }
}
advance:
diff --git a/regex.h b/regex.h
index a0758fc7aa..d5eb01d235 100644
--- a/regex.h
+++ b/regex.h
@@ -132,7 +132,6 @@ struct re_pattern_buffer
char *must; /* Pointer to exact pattern which strings should have
to be matched. */
int *must_skip; /* Pointer to exact pattern skip table for bm_search */
- char *stclass; /* Pointer to character class list at top */
long options; /* Flags for options such as extended_pattern. */
long re_nsub; /* Number of subexpressions found by the compiler. */
char fastmap_accurate;