Fixing coverity issues related to resource leak on FileInputStream being created anonymously

Signed-off-by: Daan Hoogland <daan@onecht.net>