[IBMi] Use buffer's real length for pconnect check

The buffer is an unknown state, but likely all zeroes. Using zero here
would result in spurious messages in the job log.
This commit is contained in:
Calvin Buckley
2021-12-06 12:12:15 -04:00
parent 38a39e0005
commit 4fa9ae3bd2

View File

@@ -2386,7 +2386,7 @@ static int _php_db2_connect_helper( INTERNAL_FUNCTION_PARAMETERS, conn_handle **
}
/* bind col */
if (rc == SQL_SUCCESS) {
rc = SQLBindCol((SQLHSTMT)try_stmt_res->hstmt, 1, SQL_CHAR, try_date, strlen(try_date), &try_date_len);
rc = SQLBindCol((SQLHSTMT)try_stmt_res->hstmt, 1, SQL_CHAR, try_date, 32, &try_date_len);
}
/* fetch data */
if (rc == SQL_SUCCESS) {