cvs: php4 /ext/odbc php_odbc.c

From: Date: Tue, 04 Mar 2003 16:34:54 +0000
Subject: cvs: php4 /ext/odbc php_odbc.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-19359@lists.php.net to get a copy of this message
iliaa Tue Mar 4 11:34:54 2003 EDT Modified files: /php4/ext/odbc php_odbc.c Log: Fixed bug #22437. Index: php4/ext/odbc/php_odbc.c diff -u php4/ext/odbc/php_odbc.c:1.155 php4/ext/odbc/php_odbc.c:1.156 --- php4/ext/odbc/php_odbc.c:1.155 Sat Feb 15 22:48:45 2003 +++ php4/ext/odbc/php_odbc.c Tue Mar 4 11:34:52 2003 @@ -20,7 +20,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: php_odbc.c,v 1.155 2003/02/16 03:48:45 wez Exp $ */ +/* $Id: php_odbc.c,v 1.156 2003/03/04 16:34:52 iliaa Exp $ */ #ifdef HAVE_CONFIG_H #include "config.h" @@ -2190,10 +2190,7 @@ persistent = 0; } - len = strlen(db) + strlen(uid) + strlen(pwd) + sizeof(ODBC_TYPE) + 5; - hashed_details = emalloc(len); - - hashed_len = sprintf(hashed_details, "%s_%s_%s_%s_%d", ODBC_TYPE, db, uid, pwd, cur_opt); + hashed_len = spprintf(hashed_details, 0, "%s_%s_%s_%s_%d", ODBC_TYPE, db, uid, pwd, cur_opt); /* FIXME the idea of checking to see if our connection is already persistent is good, but it adds a lot of overhead to non-persistent connections. We

« previous php.cvs (#19359) next »