Minor fixes after Coverity analysis
Simplify and improve Guile FILE * in typemap

Fix incorrect special variable $name and remove unnecessary temporary
variable.