aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/cct.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/cct.c b/src/cct.c
index 1853a962..96019f2b 100644
--- a/src/cct.c
+++ b/src/cct.c
@@ -232,6 +232,8 @@ int main(int argc, char **argv) {
/* fail if an inverse operation is not available */
if (!proj_pj_info(P).has_inverse) {
fprintf (stderr, "Inverse operation not available\n");
+ if (stdout != fout)
+ fclose (fout);
return 1;
}
/* We have no API call for inverting an operation, so we brute force it. */