Tue, 25 Mar 2003 09:38:08 +0000
support both big- and little-endian TIFF files. don't crash in close_input_file() if current_input_handler is NULL.
Makefile | file | annotate | diff | revisions | |
tumble_input.c | file | annotate | diff | revisions |
1.1 --- a/Makefile Tue Mar 25 09:36:56 2003 +0000 1.2 +++ b/Makefile Tue Mar 25 09:38:08 2003 +0000 1.3 @@ -1,6 +1,6 @@ 1.4 # tumble: build a PDF file from image files 1.5 # Makefile 1.6 -# $Id: Makefile,v 1.38 2003/03/20 00:20:52 eric Exp $ 1.7 +# $Id: Makefile,v 1.39 2003/03/25 01:38:08 eric Exp $ 1.8 # Copyright 2001, 2002, 2003 Eric Smith <eric@brouhaha.com> 1.9 # 1.10 # This program is free software; you can redistribute it and/or modify 1.11 @@ -57,7 +57,7 @@ 1.12 # let me know why so I can improve this Makefile. 1.13 # ----------------------------------------------------------------------------- 1.14 1.15 -VERSION = 0.31 1.16 +VERSION = 0.32 1.17 1.18 PACKAGE = tumble 1.19
2.1 --- a/tumble_input.c Tue Mar 25 09:36:56 2003 +0000 2.2 +++ b/tumble_input.c Tue Mar 25 09:38:08 2003 +0000 2.3 @@ -2,7 +2,7 @@ 2.4 * tumble: build a PDF file from image files 2.5 * 2.6 * Input handler dispatch 2.7 - * $Id: tumble_input.c,v 1.3 2003/03/20 06:55:27 eric Exp $ 2.8 + * $Id: tumble_input.c,v 1.4 2003/03/25 01:38:08 eric Exp $ 2.9 * Copyright 2001, 2002, 2003 Eric Smith <eric@brouhaha.com> 2.10 * 2.11 * This program is free software; you can redistribute it and/or modify 2.12 @@ -110,9 +110,13 @@ 2.13 2.14 bool close_input_file (void) 2.15 { 2.16 - bool result; 2.17 + bool result = 1; 2.18 2.19 - result = current_input_handler->close_input_file (); 2.20 + if (current_input_handler) 2.21 + { 2.22 + result = current_input_handler->close_input_file (); 2.23 + current_input_handler = NULL; 2.24 + } 2.25 if (in_filename) 2.26 free (in_filename); 2.27 if (in) 2.28 @@ -127,6 +131,8 @@ 2.29 2.30 bool last_input_page (void) 2.31 { 2.32 + if (! current_input_handler) 2.33 + return (0); 2.34 return (current_input_handler->last_input_page ()); 2.35 } 2.36 2.37 @@ -135,6 +141,8 @@ 2.38 input_attributes_t input_attributes, 2.39 image_info_t *image_info) 2.40 { 2.41 + if (! current_input_handler) 2.42 + return (0); 2.43 return (current_input_handler->get_image_info (image, 2.44 input_attributes, 2.45 image_info)); 2.46 @@ -145,6 +153,8 @@ 2.47 image_info_t *image_info, 2.48 pdf_page_handle page) 2.49 { 2.50 + if (! current_input_handler) 2.51 + return (0); 2.52 return (current_input_handler->process_image (image, 2.53 input_attributes, 2.54 image_info,