Bug #52512 [Opn->Fbk]: Broken error handling in odbc_execute
| From: | felipe@php.net | Date: | Sat, 06 Nov 2010 17:55:23 +0000 |
| Subject: | Bug #52512 [Opn->Fbk]: Broken error handling in odbc_execute | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-155810@lists.php.net to get a copy of this message | ||
Edit report at http://bugs.php.net/bug.php?id=52512&edit=1
ID: 52512
Updated by: felipe@php.net
Reported by: mkoegler at auto dot tuwien dot ac dot at
Summary: Broken error handling in odbc_execute
-Status: Open
+Status: Feedback
Type: Bug
Package: ODBC related
Operating System: any
PHP Version: 5.3.3
Block user comment: N
New Comment:
Thank you for this bug report. To properly diagnose the problem, we
need a short but complete example script to be able to reproduce
this bug ourselves.
A proper reproducing script starts with <?php and ends with ?>,
is max. 10-20 lines long and does not require any external
resources such as databases, etc. If the script requires a
database to demonstrate the issue, please make sure it creates
all necessary tables, stored procedures etc.
Please avoid embedding huge scripts into the report.
Previous Comments:
------------------------------------------------------------------------
[2010-08-02 10:57:53] mkoegler at auto dot tuwien dot ac dot at
Description:
------------
odbc_execute has problems in its error handling:
* The list of open file descriptors for parameters is not closed
properly
params[i].fp is not initialized with -1 => close may be called with a
value leftover in memory by safe_emalloc.
* In the case of some errors, the file descriptors are not closed
* The return value of SQLDescribeParam and SQLBindParameter are not
checked
Adding these error checks also yields to better error messages with some
database systems.
------------------------------------------------------------------------
--
Edit this bug report at http://bugs.php.net/bug.php?id=52512&edit=1