Skip to content

Commit

Permalink
Apparently delete doesn't need to worry about nullptr so removing thi…
Browse files Browse the repository at this point in the history
…s check.
  • Loading branch information
EpsilonPrime committed Feb 9, 2024
1 parent 755c4ef commit c28f6f0
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions export/planloader/planloader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,8 @@ SerializedPlan* load_substrait_plan(const char* filename) {
}

void free_substrait_plan(SerializedPlan* plan) {
if (plan->buffer) {
delete[] plan->buffer;
}
if (plan->errorMessage) {
delete[] plan->errorMessage;
}
delete[] plan->buffer;
delete[] plan->errorMessage;
delete plan;
}

Expand Down

0 comments on commit c28f6f0

Please sign in to comment.