diff options
author | Simon MacMullen <simon@rabbitmq.com> | 2014-12-03 17:38:49 +0000 |
---|---|---|
committer | Simon MacMullen <simon@rabbitmq.com> | 2014-12-03 17:38:49 +0000 |
commit | 6923004b2a25cf5e7e0006e1d734d395691e56b6 (patch) | |
tree | dc8287e5f6ef7826edcf2eb54a7950603af56900 | |
parent | f9cf13987aecfe7756db2de53bfd89149ad59aab (diff) | |
download | rabbitmq-server-6923004b2a25cf5e7e0006e1d734d395691e56b6.tar.gz |
Fix dirty recovery.
-rw-r--r-- | src/rabbit_variable_queue.erl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rabbit_variable_queue.erl b/src/rabbit_variable_queue.erl index d63378eb..c703d3b9 100644 --- a/src/rabbit_variable_queue.erl +++ b/src/rabbit_variable_queue.erl @@ -455,7 +455,11 @@ init(#amqqueue { name = QueueName, durable = IsDurable }, Terms, case IsDurable of true -> C = msg_store_client_init(?PERSISTENT_MSG_STORE, PRef, MsgOnDiskFun, AsyncCallback), - {C, fun (MId) -> rabbit_msg_store:contains(MId, C) end}; + {C, fun (MsgId) when is_binary(MsgId) -> + rabbit_msg_store:contains(MsgId, C); + (#basic_message{}) -> + true + end}; false -> {undefined, fun(_MsgId) -> false end} end, TransientClient = msg_store_client_init(?TRANSIENT_MSG_STORE, |