diff --git a/src/shared/mgmt.c b/src/shared/mgmt.c
index 3e9b9ee..b869fa6 100644
--- a/src/shared/mgmt.c
+++ b/src/shared/mgmt.c
request = queue_remove_if(mgmt->pending_list,
match_request_opcode_index, &match);
+ if (!request) {
+ util_debug(mgmt->debug_callback, mgmt->debug_data,
+ "Unable to find request for opcode 0x%04x",
+ opcode);
+
+ /* Attempt to remove with no opcode */
+ request = queue_remove_if(mgmt->pending_list,
+ match_request_index,
+ UINT_TO_PTR(index));
+ }
+
if (request) {
if (request->callback)
request->callback(status, length, param,