try_compile: add missing fclose() to recently added error case

In commit 236133e7 (Handle targets in the LINK_LIBRARIES of try_compile,
2013-02-09) an error return case was added without closing the file in
progress.  Add the missing fclose() call.

Spotted by sevenhill.
Merge topic 'missing-fclose-in-trycompile' into next

ce441fa try_compile: add missing fclose() to recently added error case