Fix Sonar Bad practice - Method may fail to close stream

Change-Id: I8360fce5e14a0b90134004e3255ee979fc73dfa3
Signed-off-by: Thanh Ha <thanh.ha@linuxfoundation.org>
Merge "Fix Sonar Bad practice - Method may fail to close stream"