Skip to content

Commit

Permalink
Removed the redundant NULL check when deleting Credential.
Browse files Browse the repository at this point in the history
See summary. Also moved all \`delete\` statements together in the order they
were declared in `.hpp` file.

Review: https://reviews.apache.org/r/45466/
  • Loading branch information
hatred authored and vinodkone committed Mar 30, 2016
1 parent b2c92ee commit d5d4f3c
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions src/sched/sched.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1805,14 +1805,11 @@ MesosSchedulerDriver::~MesosSchedulerDriver()
// driver.
terminate(process);
wait(process);
delete process;
}

if (credential != NULL) {
delete credential;
}

delete process;
delete latch;
delete credential;

detector.reset();

Expand Down

0 comments on commit d5d4f3c

Please sign in to comment.