Skip to content

Commit 89ac265

Browse files
committed
* MDF [mqtt_websocket] lock send_cb
Signed-off-by: Jaylin <jaylin@emqx.io>
1 parent 2571eb0 commit 89ac265

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/sp/transport/mqttws/nmq_websocket.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ wstran_pipe_send_cb(void *arg)
8282

8383
taio = p->txaio;
8484
uaio = p->user_txaio;
85-
// nni_mtx_lock(&p->mtx);
85+
nni_mtx_lock(&p->mtx);
8686
rv = nni_aio_result(taio);
8787
if (nni_aio_result(taio) != 0) {
8888
log_warn(" send aio error %s", nng_strerror(rv));
@@ -93,7 +93,7 @@ wstran_pipe_send_cb(void *arg)
9393
if (uaio != NULL) {
9494
if (p->closed){
9595
nni_aio_finish_error(uaio, p->err_code);
96-
// nni_mtx_unlock(&p->mtx);
96+
nni_mtx_unlock(&p->mtx);
9797
return;
9898
}
9999
if (rv != 0) {
@@ -102,7 +102,7 @@ wstran_pipe_send_cb(void *arg)
102102
nni_aio_finish(uaio, 0, 0);
103103
}
104104
}
105-
// nni_mtx_unlock(&p->mtx);
105+
nni_mtx_unlock(&p->mtx);
106106
}
107107

108108
static void

0 commit comments

Comments
 (0)