abies Sat Apr 3 06:00:23 2004 EDT Modified files: /php-src/ext/interbase interbase.c Log: Change definition of ISC_LONG_[MIN|MAX] to please MSVC. http://cvs.php.net/diff.php/php-src/ext/interbase/interbase.c?r1=1.209&r2=1.210&ty=u Index: php-src/ext/interbase/interbase.c diff -u php-src/ext/interbase/interbase.c:1.209 php-src/ext/interbase/interbase.c:1.210 --- php-src/ext/interbase/interbase.c:1.209 Thu Apr 1 06:38:23 2004 +++ php-src/ext/interbase/interbase.c Sat Apr 3 06:00:14 2004 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: interbase.c,v 1.209 2004/04/01 11:38:23 abies Exp $ */ +/* $Id: interbase.c,v 1.210 2004/04/03 11:00:14 abies Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -30,7 +30,7 @@ #include "php.h" -#define FILE_REVISION "$Revision: 1.209 $" +#define FILE_REVISION "$Revision: 1.210 $" #if HAVE_IBASE @@ -50,8 +50,8 @@ #define IBDEBUG(a) #endif -#define ISC_LONG_MIN (1 << (8*sizeof(ISC_LONG)-1)) -#define ISC_LONG_MAX ~ISC_LONG_MIN +#define ISC_LONG_MIN INT_MIN +#define ISC_LONG_MAX INT_MAX #define QUERY_RESULT 1 #define EXECUTE_RESULT 2 @@ -872,7 +872,7 @@ { char hash[16], *args[] = { NULL, NULL, NULL, NULL, NULL }; int i, len[] = { 0, 0, 0, 0, 0 }; - long largs[] = { 0, SQL_DIALECT_CURRENT }; + long largs[] = { 0, 0 }; PHP_MD5_CTX hash_context; list_entry new_index_ptr, *le; isc_db_handle db_handle = NULL; @@ -2373,7 +2373,7 @@ ib_link->dialect = SQL_DIALECT_CURRENT; ib_link->tr_list = NULL; ib_link->event_head = NULL; - + ZEND_REGISTER_RESOURCE(return_value, ib_link, le_link); zend_list_addref(Z_LVAL_P(return_value)); IBG(default_link) = Z_LVAL_P(return_value); @@ -2518,11 +2518,9 @@ * - num_rows() for SELECT ... FOR UPDATE is broken -> never returns a * higher number than the number of records fetched so far (no pre-fetch); * - the result of num_rows() for other statements is merely a lower bound - * on the number of records => calling ibase_num_rows() again after a couple - * of fetches will most likely return a new (higher) figure for large result - * sets. - * - * 12-aug-2003 Ard Biesheuvel + * on the number of records => calling ibase_num_rows() again after a couple + * of fetches will most likely return a new (higher) figure for large result + * sets. */ zval **result_arg; @@ -3466,7 +3464,7 @@ } /* don't return the generator value as a string unless it doesn't fit in a long */ -#ifdef SQL_INT64 +#if SQL_INT64 && SIZEOF_LONG < 8 if (result < LONG_MIN || result > LONG_MAX) { char res[24]; @@ -3478,7 +3476,7 @@ } /* }}} */ - + #endif /* HAVE_IBASE */ /*
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php