--- /dev/null
+mySQL 3.x driver for PDO
+George Schlossnagle
#include "php_pdo_mysql.h"
#include "php_pdo_mysql_int.h"
-int _mysql_error(char *what, int errno, const char *file, int line TSRMLS_DC) /* {{{ */
+int _pdo_mysql_error(char *what, int errno, const char *file, int line TSRMLS_DC) /* {{{ */
{
switch (errno) {
default:
}
/* }}} */
-static int mysql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len, pdo_stmt_t *stmt TSRMLS_DC)
+static int mysql_handle_preparer(pdo_dbh_t *dbh, const char *sql, long sql_len, pdo_stmt_t *stmt, long options, zval *driver_options TSRMLS_DC)
{
pdo_mysql_db_handle *H = (pdo_mysql_db_handle *)dbh->driver_data;
pdo_mysql_stmt *S = ecalloc(1, sizeof(pdo_mysql_stmt));
/* stuff we use in a mySQL database handle */
typedef struct {
MYSQL *server;
- unsigned int last_err;
+ int last_err;
unsigned attached:1;
unsigned _reserved:31;
} pdo_mysql_db_handle;
extern pdo_driver_t pdo_mysql_driver;
-extern int _mysql_error(char *what, int errno, const char *file, int line TSRMLS_DC);
-#define pdo_mysql_error(w,s) _mysql_error(w, s, __FILE__, __LINE__ TSRMLS_CC)
+extern int _pdo_mysql_error(char *what, int errno, const char *file, int line TSRMLS_DC);
+#define pdo_mysql_error(w,s) _pdo_mysql_error(w, s, __FILE__, __LINE__ TSRMLS_CC)
extern int mysql_handle_error(pdo_dbh_t *dbh, pdo_mysql_db_handle *H, int errcode);
extern struct pdo_stmt_methods mysql_stmt_methods;