Skip to content

Commit c9f54d8

Browse files
committed
DPL: improve reporting of why the loop was triggered
1 parent b0865e4 commit c9f54d8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

Framework/Core/src/DPLWebSocket.cxx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -509,7 +509,7 @@ void ws_client_write_callback(uv_write_t* h, int status)
509509
free(h);
510510
return;
511511
}
512-
context->state->loopReason |= DeviceState::WS_COMMUNICATION;
512+
context->state->loopReason |= (DeviceState::WS_COMMUNICATION | DeviceState::WS_READING);
513513
if (context->buf.base) {
514514
free(context->buf.base);
515515
}
@@ -520,7 +520,7 @@ void ws_client_write_callback(uv_write_t* h, int status)
520520
void ws_client_bulk_write_callback(uv_write_t* h, int status)
521521
{
522522
BulkWriteRequestContext* context = (BulkWriteRequestContext*)h->data;
523-
context->state->loopReason |= DeviceState::WS_COMMUNICATION;
523+
context->state->loopReason |= (DeviceState::WS_COMMUNICATION | DeviceState::WS_WRITING);
524524
if (status < 0) {
525525
LOG(error) << "uv_write error: " << uv_err_name(status);
526526
free(h);

0 commit comments

Comments
 (0)