From 1d529ee2940d47722dfc872b9d94f2a8d060ffeb Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Tue, 16 Jul 2024 10:11:15 +1000 Subject: [PATCH] Updated odbc32-fixes patchset Fixes when writing based of the column handle. Just check if we have been set seem enough for now. --- ...cFieldW-pass-correct-handle-onto-dri.patch | 20 +++++++++++-------- 1 file changed, 12 insertions(+), 8 deletions(-) diff --git a/patches/odbc32-fixes/0012-odbc32-SQLSetDescFieldW-pass-correct-handle-onto-dri.patch b/patches/odbc32-fixes/0012-odbc32-SQLSetDescFieldW-pass-correct-handle-onto-dri.patch index 153ca0fd..eca80ed1 100644 --- a/patches/odbc32-fixes/0012-odbc32-SQLSetDescFieldW-pass-correct-handle-onto-dri.patch +++ b/patches/odbc32-fixes/0012-odbc32-SQLSetDescFieldW-pass-correct-handle-onto-dri.patch @@ -1,17 +1,17 @@ -From 5b252124f328a2c0c5e2b80b7d1579f08761f00d Mon Sep 17 00:00:00 2001 +From d674ddfe44df7b744c2e5a957b49fb5cd924a24e Mon Sep 17 00:00:00 2001 From: Alistair Leslie-Hughes Date: Sat, 13 Jul 2024 15:23:10 +1000 Subject: [PATCH] odbc32: SQLSetDescFieldW pass correct handle onto driver --- - dlls/odbc32/proxyodbc.c | 7 ++++--- - 1 file changed, 4 insertions(+), 3 deletions(-) + dlls/odbc32/proxyodbc.c | 11 ++++++++--- + 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/dlls/odbc32/proxyodbc.c b/dlls/odbc32/proxyodbc.c -index c6ee7aac7c6..89d2cc29b71 100644 +index d0df1323d19..475be883bcb 100644 --- a/dlls/odbc32/proxyodbc.c +++ b/dlls/odbc32/proxyodbc.c -@@ -4095,7 +4095,7 @@ SQLRETURN WINAPI SQLGetStmtAttrW(SQLHSTMT StatementHandle, SQLINTEGER Attribute, +@@ -4334,7 +4334,7 @@ SQLRETURN WINAPI SQLGetStmtAttrW(SQLHSTMT StatementHandle, SQLINTEGER Attribute, SQLINTEGER BufferLength, SQLINTEGER *StringLength) { struct handle *handle = StatementHandle; @@ -20,7 +20,7 @@ index c6ee7aac7c6..89d2cc29b71 100644 TRACE("(StatementHandle %p, Attribute %d, Value %p, BufferLength %d, StringLength %p)\n", StatementHandle, Attribute, Value, BufferLength, StringLength); -@@ -4975,7 +4975,8 @@ done: +@@ -5246,7 +5246,8 @@ done: SQLRETURN WINAPI SQLSetDescFieldW(SQLHDESC DescriptorHandle, SQLSMALLINT RecNumber, SQLSMALLINT FieldIdentifier, SQLPOINTER Value, SQLINTEGER BufferLength) { @@ -30,12 +30,16 @@ index c6ee7aac7c6..89d2cc29b71 100644 SQLRETURN ret = SQL_ERROR; TRACE("(DescriptorHandle %p, RecNumber %d, FieldIdentifier %d, Value %p, BufferLength %d)\n", DescriptorHandle, -@@ -4991,7 +4992,7 @@ SQLRETURN WINAPI SQLSetDescFieldW(SQLHDESC DescriptorHandle, SQLSMALLINT RecNumb +@@ -5262,7 +5263,11 @@ SQLRETURN WINAPI SQLSetDescFieldW(SQLHDESC DescriptorHandle, SQLSMALLINT RecNumb } else if (handle->win32_handle) { - ret = handle->win32_funcs->SQLSetDescFieldW( handle->win32_handle, RecNumber, FieldIdentifier, Value, -+ ret = handle->win32_funcs->SQLSetDescFieldW( handle->app_param_desc.driver_hdesc, RecNumber, FieldIdentifier, Value, ++ if (handle->imp_param_desc.driver_hdesc) ++ ret = handle->win32_funcs->SQLSetDescFieldW( handle->imp_param_desc.driver_hdesc, RecNumber, FieldIdentifier, Value, ++ BufferLength ); ++ else ++ ret = handle->win32_funcs->SQLSetDescFieldW( handle->app_param_desc.driver_hdesc, RecNumber, FieldIdentifier, Value, BufferLength ); }