aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrik Nyblom <[email protected]>2010-08-27 15:36:07 +0200
committerPatrik Nyblom <[email protected]>2010-08-31 15:42:52 +0200
commitbccf8e748375559e1e4280582dc3d14446677e36 (patch)
treedad630fca9785bd448091dcbc4ad44c8ca025988
parent9c1364f58f2987284ff28ab6ca19b1e01c434c8e (diff)
downloadotp-bccf8e748375559e1e4280582dc3d14446677e36.tar.gz
otp-bccf8e748375559e1e4280582dc3d14446677e36.tar.bz2
otp-bccf8e748375559e1e4280582dc3d14446677e36.zip
Teach testcase epmd_SUITE:too_large to accept econnaborted
-rw-r--r--erts/epmd/test/epmd_SUITE.erl9
1 files changed, 7 insertions, 2 deletions
diff --git a/erts/epmd/test/epmd_SUITE.erl b/erts/epmd/test/epmd_SUITE.erl
index 51da934ac4..025f07380a 100644
--- a/erts/epmd/test/epmd_SUITE.erl
+++ b/erts/epmd/test/epmd_SUITE.erl
@@ -625,8 +625,13 @@ too_large(Config) when is_list(Config) ->
M = lists:duplicate(Size, $z),
?line ok = send(Sock,[put16(Size),M]),
sleep(?MEDIUM_PAUSE),
- ?line closed = recv(Sock,1),
- ok.
+ % With such a large packet, even the writes can fail as the
+ % daemon closes before everything is delivered -> econnaborted
+ case recv(Sock,1) of
+ closed -> ok;
+ {error,econnaborted} -> ok;
+ Other -> exit({unexpected,Other})
+ end.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%