Fix coverity issues.

:Release Notes:
Fix file descriptor closing.
Fix db corruption logging.

:Detailed Notes:
CID 52385: Handle variable 'file' going out of scope leaks the handle.
CID 11712: No check of the return value of 'remove(journal)' and 'remove(path)'.

:Testing Performed:
Sucessfully compiled and run.

:QA Notes:

:Issues Addressed:
[GF-53341] CoreOS: Fix Miscellaneous Coverity Issues

Open-webOS-DCO-1.0-Signed-off-by: Alexandr Smoktal <alexandr.smoktal@lge.com>

Change-Id: I6ade4db769bf3181e208cdda81f9c84257b73c30
Reviewed-on: https://g2g.palm.com/4081
Reviewed-by: DCO Verification
Reviewed-by: Alexandr Smoktal <alexandr.smoktal@lge.com>
Tested-by: Alexandr Smoktal <alexandr.smoktal@lge.com>
Reviewed-by: Alekseyev Oleksandr <alekseyev.oleksandr@lge.com>