Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[posix] Addressing coverity warning: Resource leak
The "assert" and "VerifyOrDie" were checking same condition, so the second validation was never executed if (rval != sizeof(key)). Additionally,"aSwapFd" was not freed on assertion. With this commit, 1. addressed the memory leak to system resources. 2. Replaced VerifyOrDie() or assert() by VerifyOrExit() 3. handle error at exit
- Loading branch information