Skip to content

Remove unused global and space indentation from ODBC header #16754

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Nov 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion ext/odbc/php_odbc.c
Original file line number Diff line number Diff line change
Expand Up @@ -545,7 +545,6 @@ PHP_MINIT_FUNCTION(odbc)
/* {{{ PHP_RINIT_FUNCTION */
PHP_RINIT_FUNCTION(odbc)
{
ODBCG(defConn) = -1;
ODBCG(num_links) = ODBCG(num_persistent);
memset(ODBCG(laststate), '\0', 6);
memset(ODBCG(lasterrormsg), '\0', SQL_MAX_MESSAGE_LENGTH);
Expand Down
19 changes: 9 additions & 10 deletions ext/odbc/php_odbc_includes.h
Original file line number Diff line number Diff line change
Expand Up @@ -187,10 +187,10 @@
#endif

typedef struct odbc_connection {
ODBC_SQL_ENV_T henv;
ODBC_SQL_CONN_T hdbc;
char laststate[6];
char lasterrormsg[SQL_MAX_MESSAGE_LENGTH];
ODBC_SQL_ENV_T henv;
ODBC_SQL_CONN_T hdbc;
char laststate[6];
char lasterrormsg[SQL_MAX_MESSAGE_LENGTH];
HashTable results;
} odbc_connection;

Expand Down Expand Up @@ -239,12 +239,11 @@ ZEND_BEGIN_MODULE_GLOBALS(odbc)
zend_long max_links;
zend_long num_persistent;
zend_long num_links;
int defConn;
zend_long defaultlrl;
zend_long defaultbinmode;
zend_long default_cursortype;
char laststate[6];
char lasterrormsg[SQL_MAX_MESSAGE_LENGTH];
zend_long defaultlrl;
zend_long defaultbinmode;
zend_long default_cursortype;
char laststate[6];
char lasterrormsg[SQL_MAX_MESSAGE_LENGTH];
/* Stores ODBC links throughout the duration of a request. The connection member may be either persistent or
* non-persistent. In the former case, it is a pointer to an item in EG(persistent_list). This solution makes it
* possible to properly free links during RSHUTDOWN (or when they are explicitly closed), while persistent
Expand Down