summaryrefslogtreecommitdiff
path: root/ext
AgeCommit message (Collapse)Author
2002-03-04Make cvs ignore mkmf.log.knu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2160 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-03-01* ext/socket/{addinfo.h,getaddrinfo.c} (gai_strerror): add consteban
qualifier only for uClibc. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2154 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-28* ext/socket/extconf.rb (have_struct_member): new method.akr
check msg_control and msg_accrights in struct msghdr. check sys/uio.h. * socket/socket.c: include sys/uio.h if available. (thread_read_select): new function. (unix_send_io): ditto. (unix_recv_io): ditto. (unix_s_socketpair): ditto. (Init_socket): define UNIXSocket#send_io, UNIXSocket#recv_io, git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2150 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-28* eval.c (rb_mod_include): load modules in argument order.matz
* st.c (st_init_table_with_size): num_bins should be prime numbers (no decrement). * st.c (rehash): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2147 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-27* ext/dbm/dbm.c (fdbm_select): 1.7 behavior.matz
* ext/gdbm/gdbm.c (fgdbm_select): ditto. * ext/sdbm/sdbm.c (fsdbm_select): ditto. * ext/dbm/dbm.c (fdbm_delete): adopt Hash#delete behavior. * ext/sdbm/sdbm.c (fsdbm_delete): ditto. * ext/gdbm/gdbm.c: need not to dup key to the block. * ext/sdbm/sdbm.c : replace RuntimeError with SDBMError. * eval.c (rb_f_missing): NoMethod error messages for true, false, nil must respond visibility like for other objects. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2145 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-27* io.c (READ_DATA_PENDING): uClibc support.eban
* random.c (rand_init): ditto. * ext/socket/{addinfo.h,getaddrinfo.c} (gai_strerror): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2143 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-26* ext/digest/sha2/sha2.c: Merge from rough. Fix a couple ofknu
off-by-one errors in Aaron Gifford's code. Obtained from: KAME via FreeBSD KAME PR: 393 FreeBSD PR: kern/34242 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2142 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-25* ext/syslog/syslog.c: Merge from rough. Use SafeStringValue().knu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2135 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-25* ext/syslog/syslog.c: Merge from rough. Turn Syslog into aknu
module keeping backward compatibility intact. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-24Merge from rough.knu
- Avoid namespace pollution. (MD5_* -> rb_Digest_MD5_*, etc.) git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2122 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-21* ext/extmk.rb.in (create_makefile): remove unnecessary -L option fromusa
LIBS macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2109 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-19Initial revisionnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2097 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-17* mkconfig.rb (Config::expand): expand ${} too.nobu
* ext/extmk.rb.in (try_link0): expand command. * ext/extmk.rb.in (try_cpp): ditto. * ext/extmk.rb.in (extmake): default $LIBPATH to $libdir git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2079 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-17* ext/digest/md5/md5init.c (Init_md5): rb_cvar_declare() isnobu
replaced by rb_cvar_set(). * ext/digest/rmd160/rmd160init.c (Init_rmd160): ditto. * ext/digest/sha1/sha1init.c (Init_sha1): ditto. * ext/digest/sha2/sha2init.c (Init_sha2): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2076 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-02-05* io.c (fptr_finalize): should raise error when fclose fails.matz
* eval.c (method_inspect): proper output format to distinguish methods and singleton methods. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2046 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-29Add wresize, resizeterm and KEY_RESIZE.ttate
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2030 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-28* eval.c (is_defined): defined?(Foo::Baz) should check constantsmatz
only, no methods. * eval.c (is_defined): should not dump core on defined?(a::b) where a is not a class nor a module. * object.c (Init_Object): remove dup and clone from TrueClass, FalseClass, and NilClass. * array.c (rb_ary_fill): Array#fill takes block to get the value to fill. * string.c (rb_str_to_i): to_i(0) auto-detects base radix. * array.c (rb_ary_initialize): fill by the block evaluation value if block is given. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2021 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-25* class.c (rb_include_module): detect cyclic module inclusion.matz
* eval.c (rb_thread_cleanup): need not to free thread stacks at process termination. * array.c (rb_ary_fetch): use the block to get the default value if the block is given. * eval.c (rb_thread_schedule): should check time only if BOTH WAIT_SELECT and WAIT_TIME. * eval.c (umethod_bind): should update rklass field. * hash.c (rb_hash_update): if a block is given, yields [key, value1, value2] to the block to resolve conflict. * string.c (rb_str_split_m): no need to consider KANJI characters, if the length of separator is 1 (byte). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2015 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-19* eval.c (rb_eval): need not to clar method cache for NODE_CLASS,matz
NODE_SCLASS. * gc.c (obj_free): need not to clear method cache on class/module finalization. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2006 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-18* io.c (rb_io_s_new): block check moved from initialize to thismatz
method. * io.c (rb_io_s_open): open should call initialize too. IO#for_fd also calls initialize. [new] * error.c (rb_sys_fail): replace INT2FIX() by INT2NUM() since errno value may not fit in Fixnum size on Hurd. * error.c (set_syserr): ditto. * dir.c (dir_s_glob): returns nil if block given. * io.c (rb_io_each_byte): should return self. * io.c (rb_io_close_m): close check added. * dir.c (dir_seek): should return pos. * parse.y (fixpos): orig may be (NODE*)1, which should not be dereferenced. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-18* ext/socket/socket.c (tcp_svr_s_open): fix typo.usa
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2003 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-17* eval.c (block_pass): allow "retry" from within argument passedmatz
block. [new] * eval.c (localjump_error): should preserve exit status in the exception object. [new] * eval.c (proc_invoke): should raise exception for "break" if it's yielding, not calling. [new] * eval.c (block_pass): should NOT raise exception for "break". [new] * eval.c (block_pass): should allow block argument relay even in the tainted mode. * ext/socket/socket.c: support subclassing by proper "initialize" calling convention. [new] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@2002 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-16* st.c: primes should be primes.matz
* eval.c (is_defined): method defined? check should honor protected too. * eval.c (block_pass): should not pass tainted block, if $SAFE > 0. * variable.c (rb_mod_remove_cvar): should pass the char*. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1996 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-11* re.c (match_select): should propagate taintness.matz
* hash.c (rb_hash_set_default): Hash#default= should return the new value. * string.c (rb_str_to_i): accepts optional base argument. [new] * numeric.c (rb_fix2str): should not handle negative fixnum values int32 via calling sprintf() directly. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2002-01-07Add.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1972 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-31* ext/curses/extconf.rb: add dir_config.eban
* Makefile.in (fake.rb): set RUBY_VERSION. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1954 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-29* ext/extmk.rb.in (have_library): do not print yes. sigh.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1947 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-29* ext/extmk.rb.in, lib/mkmf.rb (have_library): print yes.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1946 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-29* ext/extmk.rb.in, lib/mkmf.rb (have_library): accept -lmeban
unconditionally on mswin32/mingw32. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1945 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-19* ext/readline/readline.c: new methodsshugo
Readline::basic_word_break_characters, Readline::basic_word_break_characters=, Readline::completer_word_break_characters, Readline::completer_word_break_characters=, Readline::basic_quote_characters, Readline::basic_quote_characters=, Readline::completer_quote_characters, Readline::completer_quote_characters=, Readline::filename_quote_characters, Readline::filename_quote_characters=. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1924 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-19* eval.c (rb_mod_define_method): define_method should followmatz
default method visibility. * eval.c (rb_attr): should warn if the default method visibility is "module_function" (can be error). * eval.c (rb_mod_define_method): should define class/module method also if the visibility is "module_function". * eval.c (rb_mod_define_method): should call hook method "method_added", and "singleton_method_added". * string.c: use RESIZE_CAPA for capacity change. * ext/socket/socket.c (Init_socket): add listen method to TCPServer and UNIXServer. * ext/socket/socket.c (bsock_send): should raise EWOULDBLOCK exception. * ext/socket/socket.c (s_recvfrom): ditto. * ext/socket/socket.c (s_accept): ditto. * ext/socket/socket.c (udp_send): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1923 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-18* string.c (rb_str_replace): swap arguments of OBJ_INFECT.matz
* eval.c (rb_thread_schedule): should not select a thread which is not yet initialized. * time.c (time_plus): wrong boundary check. * time.c (time_minus): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1918 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-13* time.c (time_new_internal): avoid loop to calculate negativematz
div, mod. * time.c (time_cmp): should handle Bignums. * array.c (rb_ary_pop): should ELTS_SHARED flag check before REALLOC. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1909 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-10auxiliary routines update.matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-10* array.c (rb_ary_modify): should copy the internal buffer if thematz
modifying buffer is shared. * array.c (ary_make_shared): make an internal buffer of an array to be shared. * array.c (rb_ary_shift): avoid sliding an internal buffer by using shared buffer. * array.c (rb_ary_subseq): avoid copying the buffer. * parse.y (gettable): should freeze __LINE__ string. * io.c (rb_io_puts): old behavoir restored. rationale: a) if you want to call to_s for arrays, you can just call print a, "\n". b) to_s wastes memory if array (and sum of its contents) is huge. c) now any object that has to_ary is treated as an array, using rb_check_convert_type(). * hash.c (rb_hash_initialize): now accepts a block to calculate the default value. [new] * hash.c (rb_hash_aref): call "default" method to get the value corrensponding to the non existing key. * hash.c (rb_hash_default): get the default value based on the block given to 'new'. Now it takes an optinal "key" argument. "default" became the method to get the value for non existing key. Users may override "default" method to change the hash behavior. * hash.c (rb_hash_set_default): clear the flag if a block is given to 'new' * object.c (Init_Object): undef Data.allocate, left Data.new. * ext/curses/curses.c (window_scrollok): use RTEST(). * ext/curses/curses.c (window_idlok): ditto. * ext/curses/curses.c (window_keypad): ditto. * ext/curses/curses.c (window_idlok): idlok() may return void on some platforms; so don't use return value. * ext/curses/curses.c (window_scrollok): ditto for consistency. * ext/curses/curses.c: replace FIX2INT() by typechecking NUM2INT(). * parse.y (str_extend): should not process immature #$x and #@x interpolation, e.g #@#@ etc. * enum.c (enum_sort_by): sort_by does not have to be stable always. * enum.c (enum_sort_by): call qsort directly to gain performance. * util.c (ruby_qsort): ruby_qsort(qs6) is now native thread safe. * error.c (rb_sys_fail): it must be a bug if it's called when errno == 0. * regex.c (WC2MBC1ST): should not pass through > 0x80 number in UTF-8. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1896 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-07* ext/extmk.rb.in: ignore adding -Wl,-R to DLDFLAGS when the directoryusa
is $topdir. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1887 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-06* ext/extmk.rb.in: add -Wl,-R flags to DLDFLAGS on netbsdelf.usa
* lib/mkmf.rb: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1886 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-04replace have_header("curses") with have_header("curses.h")ttate
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1885 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-03* ext/socket/extconf.rb: remove -L/usr/local/lib.eban
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1876 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-12-02* configure.in: use GCC, not without_gcc. remove without_gcc.eban
* ext/curses/extconf.rb: check for curses.h. * ext/dbm/extconf.rb: check if $CFLAGS includes DBM_HDR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1873 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-29bug fix for getnstr() and wgetnstr()ttate
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1865 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-27* marshal.c (w_float): must distinguish -0.0 from 0.0.matz
* gc.c (gc_mark_all): tweak mark order for little bit better scan. * gc.c (rb_gc_mark): ditto. * gc.c (rb_gc): ditto. * enum.c (sort_by_i): slight performance boost. * gc.c (gc_mark_rest): should call gc_mark_children(), not gc_mark(). * gc.c (rb_gc_mark): may cause infinite looop. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1861 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-26Import the "syslog" module from the rough ruby project. This moduleknu
provides the interface to the UNIX system logger (syslog). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1860 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-23Curses::getstr and Window#getstr use getnstr() and wgetnstr()ttate
if they are available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-21* parse.y (str_extend): should check nesting parentheses in #{}.matz
* process.c (pst_wstopsig): returns nil unless WIFSTOPPED() is non-zero. * process.c (pst_wtermsig): returns nil unless WIFSIGNALED() is non-zero. * process.c (pst_wexitstatus): returns nil unless WIFEXITED() is non-zero. * eval.c (rb_thread_select): tv_sec and tv_usec should not be negative. * signal.c (posix_signal): do not set SA_RESTART for SIGVTALRM. * parse.y (call_args2): block_arg may follow the first argument in call_args2. * eval.c (stack_check): should avoid stack length check during raising SystemStackError exception. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-19* parse.y (parse_regx): should raise error on untermitatedmatz
expression interpolation. * pack.c (pack_unpack): should give length to utf8_to_uv(). * pack.c (utf8_to_uv): add length check. * massages: replace "wrong #" by "wrong number". * marshal.c (w_float): output Infinity and NaN explicitly. * marshal.c (r_object): support new explicit float format. * eval.c (rb_thread_wait_for): select may cause ERESTART on Solaris. * eval.c (rb_thread_select): ditto. * array.c (rb_ary_join): dumped core if sep is not T_STRING nor T_NIL. * array.c (rb_ary_join): buffer size calculattion was wrong. * array.c (rb_ary_to_s): if rb_output_fs is nil, insert newlines between array elements (use rb_default_rs as newline litral) [experimental]. * gc.c (init_mark_stack): no need to clear mark_stack. * gc.c (gc_mark_all): need to handle finalizer mark. * gc.c (gc_mark_rest): use MEMCPY instead of memcpy. * gc.c (rb_gc_mark): earlier const check to avoid pusing special constants into mark stack. * numeric.c (fix_to_s): 'to_s' now takes optional argument to specify radix. [new] * bignum.c (rb_big_to_s): ditto. [new] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1842 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-13tkutil needed to be updatedmatz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1831 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-11-13* signal.c (sighandle): should not re-register sighandler ifmatz
POSIX_SIGNAL is defined. * eval.c (error_print): errat array may be empty. * eval.c (rb_eval_cmd): should not upgrade safe level unless explicitly specified by argument newly added. * signal.c (sig_trap): should not allow tainted trap closure. * variable.c (rb_f_trace_var): should not allow trace_var on safe level higher than 3. * variable.c (rb_f_trace_var): should not allow tainted trace closure. * gc.c: do not use static stack until system stack overflows. * eval.c (eval): should call Exception#exception instead of calling rb_exc_new3() directly. * error.c (exc_exception): set "mesg" directly to the clone. it might be better to set mesg via some method for flexibility. * variable.c (cvar_override_check): should print original module name, if 'a' is T_ICLASS. * parse.y (yylex): float '1_.0' should not be allowed. * variable.c (var_getter): should care about var as Qfalse (ruby-bugs#PR199). * array.c (cmpint): <=> or block for {min,max} may return bignum. * array.c (sort_1): use rb_compint. * array.c (sort_2): ditto. * enum.c (min_ii): ditto. * enum.c (min_ii): ditto. * enum.c (max_i): ditto. * enum.c (max_ii): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1826 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-10-29 * intern.h (rb_protect_inspect): follow the change of array.c.usa
* eval.c (rb_exec_end_proc): follow the change of rb_protect(). * eval.c (method_proc, umethod_proc, rb_catch): cast the first parameter of rb_iterate() to avoid VC++ warning. * range.c (range_step): ditto. * ext/sdbm/init.c (fsdbm_update, fsdbm_replace): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1801 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2001-10-29* parse.y (str_extend): shuould allow interpolation of $-x.matz
* variable.c (rb_cvar_set): empty iv_tbl may cause infinite loop. * variable.c (rb_cvar_get): ditto. * variable.c (cvar_override_check): ditto. * bignum.c (rb_big_eq): convert Bignum to Float, instead of reverse. * time.c (time_localtime): getting tm should not be prohibited for frozen time objects. * time.c (time_gmtime): ditto. * version.c (Init_version): freeze RUBY_VERSION, RUBY_RELEASE_DATE, and RUBY_PLATFORM. * file.c (Init_File): freeze File::SEPARATOR, ALT_SEPARATOR and PATH_SEPARATOR. * file.c (rb_stat_cmp): should check operand type before calling get_stat(). * eval.c (rb_eval_cmd): should not invoke "call" with a block on any occasion. * numeric.c (fix_aref): idx may be a Bignum. * numeric.c (num_remainder): a bug in Numeric#remainder. * eval.c (rb_exec_end_proc): END might be called within END block. * class.c (rb_mod_clone): should not copy class name, since clone should remain anonymous. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@1800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e