Allow output files to overwrite input files (bug #21280). Thanks to
[pspp-builds.git] / src / language / data-io / print.c
index 8ec63c4d4f2431a392bae04446c01516fee85563..86d69ea997ed338c630e350c1812e82f1445409e 100644 (file)
@@ -204,11 +204,13 @@ internal_cmd_print (struct lexer *lexer, struct dataset *ds,
   add_transformation (ds, print_trns_proc, print_trns_free, trns);
 
   pool_destroy (tmp_pool);
+  fh_unref (fh);
 
   return CMD_SUCCESS;
 
  error:
   print_trns_free (trns);
+  fh_unref (fh);
   return CMD_FAILURE;
 }
 \f