[Asterisk-code-review] res_odbc.h: Added StrLen_or_IndPtr for use in SQLBindParameter (asterisk[16])

Alexei Gradinari asteriskteam at digium.com
Mon Mar 2 10:00:03 CST 2020


Alexei Gradinari has posted comments on this change. ( https://gerrit.asterisk.org/c/asterisk/+/13851 )

Change subject: res_odbc.h: Added StrLen_or_IndPtr for use in SQLBindParameter
......................................................................


Patch Set 1:

Whats version of Ignite is affected?

According to ODBC specification

https://docs.microsoft.com/en-us/sql/odbc/reference/syntax/sqlbindparameter-function?view=sql-server-ver15#strlen_or_indptr-argument
"If StrLen_or_IndPtr is a null pointer, the driver assumes that all input parameter values are non-NULL and that character and binary data is null-terminated."

https://www.ibm.com/support/knowledgecenter/en/SSEPEK_11.0.0/odbc/src/tpc/db2z_fnbindparameter.html
"If the fCType argument indicates character data (explicitly, or implicitly with SQL_C_DEFAULT), and the pcbValue argument is set to NULL, it is assumed that the application always provides a nul-terminated string in the buffer to which the rgbValue argument points. This null setting also implies that the parameter marker never uses null values."

I think it was fixed in Ignite v2.3
https://issues.apache.org/jira/browse/IGNITE-6211
"ODBC: SQLBindParameter should not unbind parameter if the ParameterValuePtr is NULL"


-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/13851
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: Ia8c3fda14b9008e22fb4893204911259f600b32e
Gerrit-Change-Number: 13851
Gerrit-PatchSet: 1
Gerrit-Owner: Abhay Gupta <abhay at avissol.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-CC: Alexei Gradinari <alex2grad at gmail.com>
Gerrit-Comment-Date: Mon, 02 Mar 2020 16:00:03 +0000
Gerrit-HasComments: No
Gerrit-Has-Labels: No
Gerrit-MessageType: comment
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200302/261c37dd/attachment-0001.html>


More information about the asterisk-code-review mailing list