|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
[2007-05-18 11:21 UTC] idvis at seznam dot cz
Description: ------------ My opinioin to #41345 tony2001@php.net comment: I think, that this is bug. I have the similar experience - after upgrading from PHP 5.2.1 to PHP 5.2.2 I cannot work with filled blob fields. Warnings: ibase_blob_info() - unrecognized BLOB field in ... Downgrade back to 5.2.1 fixes the problem. So I expect, that this is bug only in 5.2.2. Tested on the following two cases: 1. Win2000Pro, Apache 2.3, php as ISAPI module, database Firebird 1.53 2. WinXPPro, Apache 2.4, php as CGI, database Firebird 1.53 Tom Reproduce code: --------------- //... $con= ... connecting to db was before.... $query=ibase_query($con,"SELECT SOMEBLOBFIELD FROM TB_WITHBLOB"); $record=ibase_fetch_row($query); $blobinfo = ibase_blob_info($record[0]); //<-- warning Warning: ibase_blob_info() [function.ibase-blob-info]: Unrecognized BLOB ID in .... //some code bellow... Expected result: ---------------- I expect no warning :-) Actual result: -------------- arning Warning: ibase_blob_info() [function.ibase-blob-info]: Unrecognized BLOB ID in... PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
|
|||||||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Oct 26 10:00:01 2025 UTC |
PHP Bug? See below that the codes is differs from version 5.2.1 to earlier: The PHP 5.2.1 code char *_php_ibase_quad_to_string(ISC_QUAD const qd) /* {{{ */ { char *result = (char *) emalloc(BLOB_ID_LEN+1); /* shortcut for most common case */ if (sizeof(ISC_QUAD) == sizeof(ISC_UINT64)) { sprintf(result, "0x%0*" LL_MASK "x", 16, *(ISC_UINT64*)(void *) &qd); } else { ISC_UINT64 res = ((ISC_UINT64) qd.gds_quad_high << 0x20) | qd.gds_quad_low; sprintf(result, "0x%0*" LL_MASK "x", 16, res); } result[BLOB_ID_LEN] = '\0'; return result; } /* }}} */ The PHP 5.2.3 or 5.2.2 char *_php_ibase_quad_to_string(ISC_QUAD const qd) /* {{{ */ { char *result; /* shortcut for most common case */ if (sizeof(ISC_QUAD) == sizeof(ISC_UINT64)) { spprintf(&result, BLOB_ID_LEN+1, "0x%0*" LL_MASK "x", 16, *(ISC_UINT64*)(void *) &qd); } else { ISC_UINT64 res = ((ISC_UINT64) qd.gds_quad_high << 0x20) | qd.gds_quad_low; spprintf(&result, BLOB_ID_LEN+1, "0x%0*" LL_MASK "x", 16, res); } return result; } /* }}} */