aboutsummaryrefslogtreecommitdiffstats
path: root/test/socket
diff options
context:
space:
mode:
authorodaira <odaira@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-03-10 00:55:37 +0000
committerodaira <odaira@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2016-03-10 00:55:37 +0000
commitacfd12ae36cb5246f8d88932c88b95646e1916bf (patch)
tree0009ffa75b7cbb679cc8fdfc7f25897e25a4a628 /test/socket
parent75b61aa31646a2b598a5a64f3eeacdd0799e51ff (diff)
downloadruby-acfd12ae36cb5246f8d88932c88b95646e1916bf.tar.gz
* test/socket/test_socket.rb (test_udp_recvmsg_truncation):
AIX does not set the MSG_TRUNC flag for a message partially read by recvmsg(2) with the MSG_PEEK flag set. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54073 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'test/socket')
-rw-r--r--test/socket/test_socket.rb3
1 files changed, 2 insertions, 1 deletions
diff --git a/test/socket/test_socket.rb b/test/socket/test_socket.rb
index a34d0e8b2a..7e75837e8f 100644
--- a/test/socket/test_socket.rb
+++ b/test/socket/test_socket.rb
@@ -709,7 +709,8 @@ class TestSocket < Test::Unit::TestCase
s2.send("a" * 100, 0)
ret, addr, rflags = s1.recvmsg(10, Socket::MSG_PEEK)
assert_equal "a" * 10, ret
- assert_equal Socket::MSG_TRUNC, rflags & Socket::MSG_TRUNC if !rflags.nil?
+ # AIX does not set MSG_TRUNC for a message partially read with MSG_PEEK.
+ assert_equal Socket::MSG_TRUNC, rflags & Socket::MSG_TRUNC if !rflags.nil? && /aix/ !~ RUBY_PLATFORM
ret, addr, rflags = s1.recvmsg(10, 0)
assert_equal "a" * 10, ret
assert_equal Socket::MSG_TRUNC, rflags & Socket::MSG_TRUNC if !rflags.nil?