Skip to content

Commit

Permalink
fixed
Browse files Browse the repository at this point in the history
  • Loading branch information
NikitaUnisikhin committed Jan 26, 2024
1 parent 999672b commit a5474f3
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions sources/frontend.c
Original file line number Diff line number Diff line change
Expand Up @@ -996,7 +996,7 @@ static od_frontend_status_t od_frontend_remote_client(od_relay_t *relay,
"%s", kiwi_fe_type_to_string(type));

od_frontend_status_t retstatus = OD_OK;
machine_msg_t *msg;
machine_msg_t *msg = NULL;
bool forwarded = 0;
switch (type) {
case KIWI_FE_COPY_DONE:
Expand Down Expand Up @@ -1513,7 +1513,7 @@ static od_frontend_status_t od_frontend_remote_client(od_relay_t *relay,
}

/* If the retstatus is not SKIP */
if (route->rule->pool->reserve_prepared_statement && forwarded != 1) {
if (route->rule->pool->reserve_prepared_statement && forwarded != 1 && msg != NULL) {
msg = kiwi_fe_copy_msg(msg, data, size);
od_write(&server->io, msg);
retstatus = OD_SKIP;
Expand Down

0 comments on commit a5474f3

Please sign in to comment.