summaryrefslogtreecommitdiff
path: root/ext/socket/socket.c
AgeCommit message (Collapse)Author
2008-08-31* include/ruby/intern.h: rename RB_UBF_DFL toko1
RUBY_UBF_IO and RUBY_UBF_PROCESS. Because there is no default (universal) unblocking function. * ext/socket/socket.c, file.c, io.c, process.c, thread.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18985 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-31* ext/socket/socket.c (lookup_order_table): constified.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18981 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-31* ext/coverage/coverage.c (rb_mCoverage): removed unneeded static variable.nobu
* ext/socket/socket.c (unix_recv_io): ditto. * ext/socket/socket.c (mConst): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18977 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-23* include/ruby/io.h (rb_io_t): remove path field and add pathv field.akr
(MakeOpenFile): initialize pathv as Qnil. * gc.c: mark pathv field in T_FILE. * io.c: follow the rb_io_t field change. * file.c: ditto. * ext/socket/socket.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18782 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-09* stable/ext/socket/socket.c (NI_MAXHOST, NI_MAXSERV): fixed invalidnobu
preprocessor directives. a patch from Peter Bowen at [ruby-core:18211]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18450 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-08-06* eval_intern.h: Add support to Haiku. see [ruby-core:18110]naruse
* include/ruby/defines.h: ditto. * configure.in: ditto. * thread_pthread.c: ditto. * io.c: ditto. * lib/mkmf.rb: ditto. * ext/socket/getaddrinfo.c: ditto. * ext/socket/extconf.rb: ditto. * ext/socket/socket.c: ditto. * ext/socket/addrinfo.h: ditto. * ext/socket/getnameinfo.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18402 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-22 * ext/socket/socket.c (connect_blocking, socks_connect_blocking,usa
ruby_connect): cast. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18155 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-17 * ext/socket/socket.c (ruby_connect): select() for connect() hasusa
mean only when the socket is non-blocking. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18104 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-15 * ext/socket/socket.c (ruby_connect, s_accept): came back blockingusa
region because other thread/process maybe read/write the socket between select() and connect()/accept(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-15 * ext/socket/socket.c (ruby_connect, s_accept): no need to wrap byusa
blocking region if checked before readable/writable by select. * ext/socket/socket.c (bsock_send, s_recvfrom, udp_send, unix_send_io, unix_recv_io): should check readable/writable before blocking calling blocking functions. see [ruby-dev:35446] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18070 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-12* ext/socket/socket.c: use PRIuSIZE.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@18041 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-06* ext/socket/socket.c (bsock_send, s_recvfrom, ruby_connect, s_accept),nobu
(udp_send, unix_send_io, unix_recv_io): blocking region support. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17907 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-07-05* ext/socket/socket.c (host_str): fix type mismatch in rb_raiseakr
format and argument. (port_str): ditto. (unix_recv_io): ditto. (sock_s_unpack_sockaddr_un): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17898 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-24 * ext/socket/socket.c (init_sock): socket is binmode on platformsusa
which support binmode. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17551 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-06-09* ext/socket/socket.c: constified.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@17055 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-06* $Date$ keyword removed to avoid inclusion of locale dependentakr
string. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14912 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2008-01-02* util.c (ruby_strtoul): locale independent strtoul is implemented toakr
avoid "i".to_i(36) cause 0 under tr_TR locale. This is newly implemented, not a copy of missing/strtoul.c. * include/ruby/ruby.h (ruby_strtoul): declared. (STRTOUL): defined to use ruby_strtoul. * bignum.c, pack.c, ext/socket/socket.c: use STRTOUL. * configure.in (strtoul): don't check. * missing/strtoul.c: removed. * include/ruby/missing.h (strtoul): removed. * common.mk (strtoul.o): removed. * LEGAL (missing/strtoul.c): removed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14850 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-12-29use EWOULDBLOCK as an example in document.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14788 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-12-27* ext/socket/socket.c: a patch to support IRIX from Andrewmatz
Thompson <andrew@hijacked.us> in [ruby-core:14447]. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@14725 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-10-23rescue Errno::EWOULDBLOCK as well as Errno::EAGAIN in sample code in rdoc.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13759 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-10-14* ext/socket/socket.c (s_accept_nonblock): make accepted fdakr
nonblocking. [ruby-talk:274079] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13699 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-08-25* encoding.c: provide basic features for M17N.matz
* parse.y: encoding aware parsing. * parse.y (pragma_encoding): encoding specification pragma. * parse.y (rb_intern3): encoding specified symbols. * string.c (rb_str_length): length based on characters. for older behavior, bytesize method added. * string.c (rb_str_index_m): index based on characters. rindex as well. * string.c (succ_char): encoding aware succeeding string. * string.c (rb_str_reverse): reverse based on characters. * string.c (rb_str_inspect): encoding aware string description. * string.c (rb_str_upcase_bang): encoding aware case conversion. downcase, capitalize, swapcase as well. * string.c (rb_str_tr_bang): tr based on characters. delete, squeeze, tr_s, count as well. * string.c (rb_str_split_m): split based on characters. * string.c (rb_str_each_line): encoding aware each_line. * string.c (rb_str_each_char): added. iteration based on characters. * string.c (rb_str_strip_bang): encoding aware whitespace stripping. lstrip, rstrip as well. * string.c (rb_str_justify): encoding aware justifying (ljust, rjust, center). * string.c (str_encoding): get encoding attribute from a string. * re.c (rb_reg_initialize): encoding aware regular expression * sprintf.c (rb_str_format): formatting (i.e. length count) based on characters. * io.c (rb_io_getc): getc to return one-character string. for older behavior, getbyte method added. * ext/stringio/stringio.c (strio_getc): ditto. * io.c (rb_io_ungetc): allow pushing arbitrary string at the current reading point. * ext/stringio/stringio.c (strio_ungetc): ditto. * ext/strscan/strscan.c: encoding support. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@13261 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-06-10* include/ruby: moved public headers.nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12501 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-04-25clear cmsg padding.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12220 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-04-25* ext/socket/socket.c (unix_send_io, unix_recv_io): use CMSG_DATA toakr
align file descriptor appropriately. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12217 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-04-03 * ext/socket/socket.c (s_recv, s_recvfrom): some systems (such asusa
windows) doesn't set fromlen if the socket is connection-oriented. reported by Bram Whillock in [ruby-core:10512] [ruby-Bugs#9061] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12138 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-03-19* regparse.c, etc.: K&R to ANSI code cleanup patch from Stefanmatz
Huehner <stefan at huehner.org>. [ruby-core:10543] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@12095 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-24* file.c, gc.c, io.c, ruby.h, rubyio.h, win32/win32.h (rb_io_t):nobu
renamed from OpenFile. * ext/dl/cptr.c, ext/io/wait/wait.c, ext/openssl/ossl.h, ext/openssl/ossl_bio.c, ext/openssl/ossl_ssl.c, ext/pty/pty.c, ext/readline/readline.c, ext/socket/socket.c: ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11869 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-19* ext/socket/socket.c (unix_peeraddr): wrong syscall name in errormatz
message for #peeraddr. a patch from Sam Roberts <sroberts at uniserve.com>. [ruby-core:10366] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11778 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-02-13* ext/socket/socket.c (init_unixsock): path may contain NUL formatz
abstract unix sockets. [ruby-core:10288] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11712 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2007-01-22* ext/socket/socket.c: fix errors in socket sample code.matz
[ruby-core:09992] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11552 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-11-02* ext/socket/socket.c (ruby_getnameinfo__aix): AF_INET6 workaroundmatz
for AIX. a patch from Yutaka Kanemoto <kinpoco AT gmail.com>. [ruby-dev:29744] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11272 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-26socket.c: a rdoc patch from Daniel Berger <djberg96 at gmail.com>matz
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@11039 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-02* ext/socket/socket.c (ruby_connect): sockerrlen should be socklen_t.akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10843 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-02* ext/socket/extconf.rb: check arpa/inet.h for ntohs.akr
* ext/socket/socket.c: include arpa/inet.h if available. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10842 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-02* ruby.h (struct RArray): embed small arrays.matz
(RARRAY_LEN): defined for accessing array members. (RARRAY_PTR): ditto. * array.c: use RARRAY_LEN and RARRAY_PTR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10833 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-09-01* ext/socket/socket.c (socks_init): typo fixed. a patch from Svenmatz
Klemm <sven at c3d2.de>. [ruby-core:08770] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10821 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-31* ruby.h (struct RString): embed small strings.matz
(RSTRING_LEN): defined for accessing string members. (RSTRING_PTR): ditto. * string.c: use RSTRING_LEN and RSTRING_PTR. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10809 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-13* ext/socket/socket.c: ANSIfied. [ruby-core:08601]akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10722 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-07* configure.in, common.mk: AIX link issue. a patch from Yutakamatz
Kanemoto <kinpoco at gmail.com>. [ruby-dev:29190] * ext/socket/socket.c: AIX socket support. [ruby-dev:29190] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10695 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-27* string.c: RDoc update for =~ method. a patch from Alex Youngmatz
<alex at blackkettle.org>. [ruby-core:08068] * io.c (pipe_open): backout unnecessary fix on 2006-06-26. [ruby-dev:28865] * eval.c (rb_yield_0): exact argument number check now done only for lambda Proc. * eval.c (rb_yield_0): add check for number of arguments, if there's one lambda block parameter. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10412 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-26* ext/socket/socket.c (bsock_recv_nonblock): new methodakr
BasicSocket#recv_nonblock. (udp_recvfrom_nonblock): renamed from ip_recvfrom_nonblock. IPSocket#recvfrom_nonblock is moved to UDPSocket#recvfrom_nonblock. (unix_recvfrom_nonblock): removed. UNIXSocket#recvfrom_nonblock is removed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10403 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-26revert sock_sysaccept addition to [ruby-dev:28861].akr
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10399 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-26* ext/socket/socket.c (sock_accept): revert to avoid ambiguity ofmatz
argument evaluation order. [ruby-dev:28861] * ext/socket/socket.c (sock_accept_nonblock): ditto. * io.c (pipe_open): avoid closing uninitialized file descriptors. a patch from <tommy at tmtm.org> [ruby-dev:28600] * parse.y: replace terminal token names with more descriptive name, i.e. kEND to keyword_end. [ruby-list:42477] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10397 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-21* ext/socket/socket.c (sock_s_socketpair): try GC only once.akr
[ruby-dev:28778] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10362 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-19* ext/socket/socket.c (unix_sysaccept): typo fixed.matz
* ext/socket/socket.c (sock_connect): remove an unused local variable tmpaddr. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10323 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-19* ext/socket/socket.c (tcp_accept_nonblock): forgot to removematz
abandoned hacks. [ruby-dev:28740] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10322 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-17* eval.c (Init_eval): add aliases invoke_method andmatz
invoke_functional_method corresponding send and funcall respectively. [ruby-talk:197512] * parse.y (parser_yylex): returns the most typical keyword token on EXPR_FNAME. [ruby-core:7995] * ext/socket/socket.c: protoize. * parse.y (then): remove ':' from 'then' and 'do' rules. * hash.c (env_aset): raise TypeError on nil with more descriptive message. [ruby-core:07990] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10304 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-13* ext/socket/socket.c (Init_socket): remove obsolete constants:matz
IPsocket, TCPsocket, SOCKSsocket, TCPserver, UDPsocket, UNIXsocket, UNIXserver. * eval.c (formal_assign): post splat arguments should have had higher priority than optional arguments, since they are mandatory. [ruby-dev:28715] * eval.c (VIS_MASK): broken. should be 15. [ruby-dev:28715] * io.c (argf_getc): should return one-character string. [ruby-dev:28715] * io.c (rb_io_readchar): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10257 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-05* ext/socket/socket.c (sock_s_unpack_sockaddr_in): rejectakr
non-AF_INET/AF_INET6 sockaddr. (sock_s_unpack_sockaddr_un): reject non-AF_UNIX sockaddr. [ruby-dev:28691] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@10218 b2dd03c8-39d4-4d8f-98ff-823fe69b080e