[ODBCCP32] Sync with Wine Staging 4.18. CORE-16441

This commit is contained in:
Amine Khaldi 2019-11-10 14:10:08 +01:00
parent 4658658fb4
commit 6410641025
2 changed files with 7 additions and 8 deletions

View file

@ -30,7 +30,6 @@
#include "winreg.h"
#include "winnls.h"
#include "sqlext.h"
#include "wine/unicode.h"
#ifdef __REACTOS__
#undef TRACE_ON
#endif
@ -292,7 +291,7 @@ static HMODULE load_config_driver(const WCHAR *driver)
if(ret != ERROR_SUCCESS)
{
HeapFree(GetProcessHeap(), 0, filename);
push_error(ODBC_ERROR_INVALID_DSN, odbc_error_invalid_dsn);
push_error(ODBC_ERROR_COMPONENT_NOT_FOUND, odbc_error_component_not_found);
return NULL;
}
@ -320,7 +319,7 @@ static BOOL write_config_value(const WCHAR *driver, const WCHAR *args)
{
WCHAR *divider, *value;
name = heap_alloc( (strlenW(args) + 1) * sizeof(WCHAR));
name = heap_alloc( (lstrlenW(args) + 1) * sizeof(WCHAR));
if(!name)
{
push_error(ODBC_ERROR_OUT_OF_MEM, odbc_error_out_of_mem);
@ -328,7 +327,7 @@ static BOOL write_config_value(const WCHAR *driver, const WCHAR *args)
}
lstrcpyW(name, args);
divider = strchrW(name,'=');
divider = wcschr(name,'=');
if(!divider)
{
push_error(ODBC_ERROR_INVALID_KEYWORD_VALUE, odbc_error_invalid_keyword);
@ -340,7 +339,7 @@ static BOOL write_config_value(const WCHAR *driver, const WCHAR *args)
TRACE("Write pair: %s = %s\n", debugstr_w(name), debugstr_w(value));
if(RegSetValueExW(hkeydriver, name, 0, REG_SZ, (BYTE*)value,
(strlenW(value)+1) * sizeof(WCHAR)) != ERROR_SUCCESS)
(lstrlenW(value)+1) * sizeof(WCHAR)) != ERROR_SUCCESS)
ERR("Failed to write registry installed key\n");
heap_free(name);
@ -863,7 +862,7 @@ static void write_registry_values(const WCHAR *regkey, const WCHAR *driver, cons
for (; *p; p += lstrlenW(p) + 1)
{
WCHAR *divider = strchrW(p,'=');
WCHAR *divider = wcschr(p,'=');
if (divider)
{
@ -1522,7 +1521,7 @@ BOOL WINAPI SQLValidDSNW(LPCWSTR lpszDSN)
clear_errors();
TRACE("%s\n", debugstr_w(lpszDSN));
if(strlenW(lpszDSN) > SQL_MAX_DSN_LENGTH || strpbrkW(lpszDSN, invalid) != NULL)
if(lstrlenW(lpszDSN) > SQL_MAX_DSN_LENGTH || wcspbrk(lpszDSN, invalid) != NULL)
{
return FALSE;
}

View file

@ -139,7 +139,7 @@ dll/win32/npptools # Synced to WineStaging-4.18
dll/win32/ntdsapi # Synced to WineStaging-4.18
dll/win32/objsel # Synced to WineStaging-4.18
dll/win32/odbc32 # Synced to WineStaging-4.18. Depends on port of Linux ODBC.
dll/win32/odbccp32 # Synced to WineStaging-4.0
dll/win32/odbccp32 # Synced to WineStaging-4.18
dll/win32/ole32 # Synced to WineStaging-4.0
dll/win32/oleacc # Synced to WineStaging-4.0
dll/win32/oleaut32 # Synced to WineStaging-4.0