Bug #491
closedmakeが"string contains null byte"で失敗します
Description
=begin
刀野といいます。
ia64 linuxでruby 1.9のmakeが以下のメッセージで失敗します。
./miniruby -I./lib -I.ext/common -I./- -r./ext/purelib.rb ./enc/make_encdb.rb encdb.h.new ./enc enc
./tool/ifchange "encdb.h" "encdb.h.new"
encdb.h unchanged
/root/ruby/lib/fileutils.rb:967:in require': string contains null byte (ArgumentError) from /root/ruby/lib/fileutils.rb:967:in
module:FileUtils'
from /root/ruby/lib/fileutils.rb:85:in <top (required)>' from ./mkconfig.rb:11:in
require'
from ./mkconfig.rb:11:in `'
make: *** [.rbconfig.time] Error 1
file_expand_path()の中のBUFCHECKでバッファが正しく拡張されない
場合があるようです。パッチを作ってみました。
diff --git a/file.c b/file.c
index f2a6c46..f1ba684 100644
--- a/file.c
+++ b/file.c
@@ -2729,8 +2729,7 @@ file_expand_path(VALUE fname, VALUE dname, VALUE result)
if (p > buf && p[-1] == '/')
--p;
else {
- ++buflen;
- BUFCHECK(bdiff >= buflen);
- BUFCHECK(bdiff + 1 >= buflen);
*p = '/';
}
=end
Updated by ko1 (Koichi Sasada) about 16 years ago
- Assignee set to nobu (Nobuyoshi Nakada)
=begin
=end
Updated by matz (Yukihiro Matsumoto) about 16 years ago
- Status changed from Open to Closed
- % Done changed from 0 to 100
=begin
Applied in changeset r19201.
=end