Skip to content

Commit

Permalink
rabbitmq: proper check for allocated pointer
Browse files Browse the repository at this point in the history
  • Loading branch information
miconda committed Aug 22, 2023
1 parent efd94f9 commit 4d58141
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/rabbitmq/rabbitmq.c
Original file line number Diff line number Diff line change
Expand Up @@ -571,7 +571,7 @@ static int rabbitmq_connect(amqp_connection_state_t *conn)

// establish a new connection to RabbitMQ server
*conn = amqp_new_connection();
if(!conn) {
if(!*conn) {
LM_ERR("FAIL: create AMQP connection\n");
return RABBITMQ_ERR_CREATE;
}
Expand Down

0 comments on commit 4d58141

Please sign in to comment.