Skip to content

Commit da541d1

Browse files
committed
Fix double free
1 parent 7b293dd commit da541d1

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

programs/local/LocalServer.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1170,6 +1170,7 @@ DB::LocalServer * bgClickHouseLocal(int argc, char ** argv)
11701170
auto err_msg = app->getErrorMsg();
11711171
LOG_ERROR(&app->logger(), "Error running bgClickHouseLocal: {}", err_msg);
11721172
delete app;
1173+
app = nullptr;
11731174
throw DB::Exception(DB::ErrorCodes::BAD_ARGUMENTS, "Error running bgClickHouseLocal: {}", err_msg);
11741175
}
11751176
return app;

0 commit comments

Comments
 (0)