tumble_input.c

changeset 142
cfa664f3129c
parent 141
752599b50ff3
child 151
83a99cc69861
     1.1 --- a/tumble_input.c	Thu Mar 20 06:54:08 2003 +0000
     1.2 +++ b/tumble_input.c	Thu Mar 20 07:02:28 2003 +0000
     1.3 @@ -2,7 +2,7 @@
     1.4   * tumble: build a PDF file from image files
     1.5   *
     1.6   * Input handler dispatch
     1.7 - * $Id: tumble_input.c,v 1.1 2003/03/19 22:54:08 eric Exp $
     1.8 + * $Id: tumble_input.c,v 1.2 2003/03/19 23:02:28 eric Exp $
     1.9   * Copyright 2001, 2002, 2003 Eric Smith <eric@brouhaha.com>
    1.10   *
    1.11   * This program is free software; you can redistribute it and/or modify
    1.12 @@ -106,8 +106,11 @@
    1.13    result = current_input_handler->close_input_file ();
    1.14    if (in_filename)
    1.15      free (in_filename);
    1.16 -  fclose (in);
    1.17 -  in = NULL;
    1.18 +  if (in)
    1.19 +    {
    1.20 +      fclose (in);
    1.21 +      in = NULL;
    1.22 +    }
    1.23  
    1.24    return (result);
    1.25  }