summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Klishin <michael@clojurewerkz.org>2021-02-24 20:31:10 +0300
committerMichael Klishin <michael@clojurewerkz.org>2021-02-24 20:31:10 +0300
commit7ba2bde260d76ed007f041d9fd04724ca2d0188e (patch)
tree1e33ae4f8afef46eb5cb991ec85fd3198e6f2659
parent33d8ac4f79fbe470ab836e9dd57e91c9c45ab4f9 (diff)
downloadrabbitmq-server-git-7ba2bde260d76ed007f041d9fd04724ca2d0188e.tar.gz
Correctly use string:lexemes/2
-rw-r--r--deps/rabbit/src/rabbit_direct_reply_to.erl4
1 files changed, 2 insertions, 2 deletions
diff --git a/deps/rabbit/src/rabbit_direct_reply_to.erl b/deps/rabbit/src/rabbit_direct_reply_to.erl
index c205fae3d5..50e2ee6e81 100644
--- a/deps/rabbit/src/rabbit_direct_reply_to.erl
+++ b/deps/rabbit/src/rabbit_direct_reply_to.erl
@@ -35,7 +35,7 @@ compute_key_and_suffix_v1(Pid) ->
-spec decode_reply_to_v1(binary()) -> decoded_pid_and_key() | {error, any()}.
decode_reply_to_v1(Bin) ->
- case string:lexemes(Bin, ["."]) of
+ case string:lexemes(Bin, ".") of
[PidEnc, Key] -> Pid = binary_to_term(base64:decode(PidEnc)),
{ok, Pid, unicode:characters_to_binary(Key)};
_ -> {error, unrecognized_format}
@@ -63,7 +63,7 @@ compute_key_and_suffix_v2(Pid) ->
-spec decode_reply_to_v2(binary(), #{non_neg_integer() => node()}) -> decoded_pid_and_key() | {error, any()}.
decode_reply_to_v2(Bin, CandidateNodes) ->
- case string:lexemes(Bin, ["."]) of
+ case string:lexemes(Bin, ".") of
[PidEnc, Key] ->
RawPidBin = base64:decode(PidEnc),
PidParts0 = #{node := ShortenedNodename} = pid_recomposition:from_binary(RawPidBin),