From d782c712cae59d5feb00fb995704a50051ec1bbf Mon Sep 17 00:00:00 2001 From: Marcus Boerger Date: Sat, 22 Jun 2002 23:43:16 +0000 Subject: [PATCH] -exif version -missing constant (and notice) -corrected error messages --- ext/exif/exif.c | 7 ++++--- ext/standard/php_image.h | 1 + 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/ext/exif/exif.c b/ext/exif/exif.c index adc5daa3e9..3a917140d4 100644 --- a/ext/exif/exif.c +++ b/ext/exif/exif.c @@ -107,7 +107,7 @@ function_entry exif_functions[] = { }; /* }}} */ -#define EXIF_VERSION "1.3 $Id$" +#define EXIF_VERSION "1.4 $Id$" /* {{{ PHP_MINFO_FUNCTION */ @@ -205,6 +205,7 @@ PHP_MINIT_FUNCTION(exif) REGISTER_LONG_CONSTANT("IMAGETYPE_JP2", IMAGE_FILETYPE_JP2, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IMAGETYPE_JPX", IMAGE_FILETYPE_JPX, CONST_CS | CONST_PERSISTENT); REGISTER_LONG_CONSTANT("IMAGETYPE_JB2", IMAGE_FILETYPE_JB2, CONST_CS | CONST_PERSISTENT); + REGISTER_LONG_CONSTANT("IMAGETYPE_SWC", IMAGE_FILETYPE_SWC, CONST_CS | CONST_PERSISTENT); return SUCCESS; } /* }}} */ @@ -260,8 +261,8 @@ static size_t php_strnlen(char* str, size_t maxlen) { static const char * EXIF_ERROR_EALLOC = "Cannot allocate memory for all data"; static const char * EXIF_ERROR_FILEEOF = "Unexpected end of file reached"; static const char * EXIF_ERROR_CORRUPT = "File structure corrupted"; -static const char * EXIF_ERROR_THUMBEOF = "Thumbnail goes IFD boundary or end of file reached"; -static const char * EXIF_ERROR_FSREALLOC = "Illegal reallocating of undefined file section"; +static const char * EXIF_ERROR_THUMBEOF = "Thumbnail goes beyond IFD boundary or end of file reached"; +static const char * EXIF_ERROR_FSREALLOC = "Illegal reallocation of undefined file section"; #define EXIF_ERRLOG_EALLOC php_error(E_ERROR, EXIF_ERROR_EALLOC); #define EXIF_ERRLOG_FILEEOF php_error(E_WARNING, EXIF_ERROR_FILEEOF); diff --git a/ext/standard/php_image.h b/ext/standard/php_image.h index 6ca658b278..47373aeb3b 100644 --- a/ext/standard/php_image.h +++ b/ext/standard/php_image.h @@ -45,6 +45,7 @@ typedef enum IMAGE_FILETYPE_JPX, IMAGE_FILETYPE_JB2, IMAGE_FILETYPE_SWC +/* WHEN EXTENDING: PLEASE ALSO REGISTER IN ext/exif/exif.c:PHP_MINIT_FUNCTION(exif) */ } image_filetype; /* }}} */ -- 2.50.1