iolist_to_binary(Name)

This commit is contained in:
Feng 2016-01-24 13:42:59 +08:00
parent 22a282e39e
commit 0b686da281
1 changed files with 2 additions and 1 deletions

View File

@ -99,7 +99,8 @@
new(Name, Opts, AlarmFun) ->
Type = emqttd_opts:g(type, Opts, simple),
MaxLen = emqttd_opts:g(max_length, Opts, infinity),
init_q(#mqueue{type = Type, name = Name, max_len = MaxLen,
init_q(#mqueue{type = Type, name = iolist_to_binary(Name),
len = 0, max_len = MaxLen,
low_wm = low_wm(MaxLen, Opts),
high_wm = high_wm(MaxLen, Opts),
qos0 = emqttd_opts:g(queue_qos0, Opts, false),