Skip to content

Commit 462792e

Browse files
committed
Expose PDO_ODBC_TYPE to userland
1 parent 8726ae0 commit 462792e

File tree

5 files changed

+26
-1
lines changed

5 files changed

+26
-1
lines changed

UPGRADING

+3
Original file line numberDiff line numberDiff line change
@@ -497,6 +497,9 @@ PHP 8.3 UPGRADE NOTES
497497
- PCNTL:
498498
. SIGINFO
499499

500+
- PDO_ODBC
501+
. PDO_ODBC_TYPE
502+
500503
- PGSQL:
501504
. PGSQL_TRACE_SUPPRESS_TIMESTAMPS
502505
. PGSQL_TRACE_REGRESS_MODE

ext/pdo_odbc/pdo_odbc.c

+3
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
#include "pdo/php_pdo_driver.h"
2626
#include "php_pdo_odbc.h"
2727
#include "php_pdo_odbc_int.h"
28+
#include "pdo_odbc_arginfo.h"
2829

2930
/* {{{ pdo_odbc_deps[] */
3031
static const zend_module_dep pdo_odbc_deps[] = {
@@ -96,6 +97,8 @@ PHP_MINIT_FUNCTION(pdo_odbc)
9697
}
9798
#endif
9899

100+
register_pdo_odbc_symbols(module_number);
101+
99102
REGISTER_PDO_CLASS_CONST_LONG("ODBC_ATTR_USE_CURSOR_LIBRARY", PDO_ODBC_ATTR_USE_CURSOR_LIBRARY);
100103
REGISTER_PDO_CLASS_CONST_LONG("ODBC_ATTR_ASSUME_UTF8", PDO_ODBC_ATTR_ASSUME_UTF8);
101104
REGISTER_PDO_CLASS_CONST_LONG("ODBC_SQL_USE_IF_NEEDED", SQL_CUR_USE_IF_NEEDED);

ext/pdo_odbc/pdo_odbc.stub.php

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
/** @generate-class-entries */
4+
5+
/**
6+
* @var string
7+
* @cvalue PDO_ODBC_TYPE
8+
*/
9+
const PDO_ODBC_TYPE = UNKNOWN;

ext/pdo_odbc/pdo_odbc_arginfo.h

+9
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ext/pdo_odbc/tests/bug80783a.phpt

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,11 @@ Bug #80783 (PDO ODBC truncates BLOB records at every 256th byte)
44
pdo_odbc
55
--SKIPIF--
66
<?php
7+
78
require 'ext/pdo/tests/pdo_test.inc';
89
PDOTest::skip();
910

10-
if (ODBC_TYPE === "unixODBC") {
11+
if (PDO_ODBC_TYPE === "unixODBC") {
1112
die("skip Fails with unixODBC");
1213
}
1314
?>

0 commit comments

Comments
 (0)