aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/src
diff options
context:
space:
mode:
authorLukas Larsson <[email protected]>2012-09-20 15:11:33 +0200
committerLukas Larsson <[email protected]>2012-11-09 15:52:01 +0100
commit22698424dbc6efec84d71234b60290b3937f2f28 (patch)
tree8d26d989d4b7b903ae96f4f34c3de279cd3a7ee1 /lib/common_test/src
parent9604cf9378dc240d9be36d3785bfbd9731437f03 (diff)
downloadotp-22698424dbc6efec84d71234b60290b3937f2f28.tar.gz
otp-22698424dbc6efec84d71234b60290b3937f2f28.tar.bz2
otp-22698424dbc6efec84d71234b60290b3937f2f28.zip
Fix bug where require of same name at same config would return name in use
Diffstat (limited to 'lib/common_test/src')
-rw-r--r--lib/common_test/src/ct_config.erl3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/common_test/src/ct_config.erl b/lib/common_test/src/ct_config.erl
index 30bf5925c0..06a8e12f55 100644
--- a/lib/common_test/src/ct_config.erl
+++ b/lib/common_test/src/ct_config.erl
@@ -532,7 +532,8 @@ do_require(Name,Key) ->
case get_key_from_name(Name) of
{error,_} ->
allocate(Name,Key);
- {ok,Key} ->
+ {ok,NameKey} when NameKey == Key;
+ is_tuple(Key) andalso element(1,Key) == NameKey ->
%% already allocated - check that it has all required subkeys
R = make_ref(),
case get_config(Key,R,[]) of