Signed-off-by: Alistair Leslie-Hughes leslie_alistair@hotmail.com --- dlls/msdasql/session.c | 126 ++++++++++++++++++++--------------------- 1 file changed, 63 insertions(+), 63 deletions(-)
diff --git a/dlls/msdasql/session.c b/dlls/msdasql/session.c index df394264bf7..44f36f0e591 100644 --- a/dlls/msdasql/session.c +++ b/dlls/msdasql/session.c @@ -293,6 +293,7 @@ struct command IColumnsInfo IColumnsInfo_iface; IConvertType IConvertType_iface; ICommandPrepare ICommandPrepare_iface; + ICommandWithParameters ICommandWithParameters_iface; LONG refs; WCHAR *query; IUnknown *session; @@ -323,6 +324,11 @@ static inline struct command *impl_from_ICommandPrepare( ICommandPrepare *iface return CONTAINING_RECORD( iface, struct command, ICommandPrepare_iface ); }
+static inline struct command *impl_from_ICommandWithParameters( ICommandWithParameters *iface ) +{ + return CONTAINING_RECORD( iface, struct command, ICommandWithParameters_iface ); +} + static HRESULT WINAPI command_QueryInterface(ICommandText *iface, REFIID riid, void **ppv) { struct command *command = impl_from_ICommandText( iface ); @@ -352,6 +358,10 @@ static HRESULT WINAPI command_QueryInterface(ICommandText *iface, REFIID riid, v { *ppv = &command->ICommandPrepare_iface; } + else if(IsEqualGUID(&IID_ICommandWithParameters, riid)) + { + *ppv = &command->ICommandWithParameters_iface; + }
if(*ppv) { @@ -426,7 +436,6 @@ struct msdasql_rowset IColumnsInfo IColumnsInfo_iface; IAccessor IAccessor_iface; IColumnsRowset IColumnsRowset_iface; - ICommandWithParameters ICommandWithParameters_iface; IUnknown *caller; LONG refs; }; @@ -456,11 +465,6 @@ static inline struct msdasql_rowset *impl_from_IColumnsRowset ( IColumnsRowset * return CONTAINING_RECORD( iface, struct msdasql_rowset, IColumnsRowset_iface ); }
-static inline struct msdasql_rowset *impl_from_ICommandWithParameters( ICommandWithParameters *iface ) -{ - return CONTAINING_RECORD( iface, struct msdasql_rowset, ICommandWithParameters_iface ); -} - static HRESULT WINAPI msdasql_rowset_QueryInterface(IRowset *iface, REFIID riid, void **ppv) { struct msdasql_rowset *rowset = impl_from_IRowset( iface ); @@ -489,10 +493,6 @@ static HRESULT WINAPI msdasql_rowset_QueryInterface(IRowset *iface, REFIID riid, { *ppv = &rowset->IColumnsRowset_iface; } - else if(IsEqualGUID(&IID_ICommandWithParameters, riid)) - { - *ppv = &rowset->ICommandWithParameters_iface; - } else if (IsEqualGUID(&IID_IRowsetChange, riid)) { TRACE("IID_IRowsetChange not supported\n"); @@ -801,58 +801,6 @@ struct IColumnsRowsetVtbl columnrs_rs_vtbl = column_rs_GetColumnsRowset };
-static HRESULT WINAPI cmd_with_params_QueryInterface(ICommandWithParameters *iface, REFIID riid, void **out) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - return IRowset_QueryInterface(&rowset->IRowset_iface, riid, out); -} - -static ULONG WINAPI cmd_with_params_AddRef(ICommandWithParameters *iface) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - return IRowset_AddRef(&rowset->IRowset_iface); -} - -static ULONG WINAPI cmd_with_params_Release(ICommandWithParameters *iface) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - return IRowset_Release(&rowset->IRowset_iface); -} - -static HRESULT WINAPI cmd_with_params_GetParameterInfo(ICommandWithParameters *iface, DB_UPARAMS *uparams, - DBPARAMINFO **info, OLECHAR **buffer) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - FIXME("%p, %p, %p, %p\n", rowset, uparams, info, buffer); - return E_NOTIMPL; -} - -static HRESULT WINAPI cmd_with_params_MapParameterNames(ICommandWithParameters *iface, DB_UPARAMS uparams, - LPCWSTR names[], DB_LPARAMS ordinals[]) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - FIXME("%p, %ld, %p, %p\n", rowset, uparams, names, ordinals); - return E_NOTIMPL; -} - -static HRESULT WINAPI cmd_with_params_SetParameterInfo(ICommandWithParameters *iface, DB_UPARAMS uparams, - const DB_UPARAMS ordinals[], const DBPARAMBINDINFO bindinfo[]) -{ - struct msdasql_rowset *rowset = impl_from_ICommandWithParameters( iface ); - FIXME("%p, %ld, %p, %p\n", rowset, uparams, ordinals, bindinfo); - return E_NOTIMPL; -} - -struct ICommandWithParametersVtbl command_with_params_vtbl = -{ - cmd_with_params_QueryInterface, - cmd_with_params_AddRef, - cmd_with_params_Release, - cmd_with_params_GetParameterInfo, - cmd_with_params_MapParameterNames, - cmd_with_params_SetParameterInfo -}; - static HRESULT WINAPI command_Execute(ICommandText *iface, IUnknown *outer, REFIID riid, DBPARAMS *params, DBROWCOUNT *affected, IUnknown **rowset) { @@ -871,7 +819,6 @@ static HRESULT WINAPI command_Execute(ICommandText *iface, IUnknown *outer, REFI msrowset->IColumnsInfo_iface.lpVtbl = &rowset_columninfo_vtbll; msrowset->IAccessor_iface.lpVtbl = &accessor_vtbl; msrowset->IColumnsRowset_iface.lpVtbl = &columnrs_rs_vtbl; - msrowset->ICommandWithParameters_iface.lpVtbl = &command_with_params_vtbl; msrowset->refs = 1; ICommandText_QueryInterface(iface, &IID_IUnknown, (void**)&msrowset->caller);
@@ -1116,6 +1063,58 @@ struct ICommandPrepareVtbl commandprepareVtbl = commandprepare_Unprepare };
+static HRESULT WINAPI cmd_with_params_QueryInterface(ICommandWithParameters *iface, REFIID riid, void **out) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + return ICommandText_QueryInterface(&command->ICommandText_iface, riid, out); +} + +static ULONG WINAPI cmd_with_params_AddRef(ICommandWithParameters *iface) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + return ICommandText_AddRef(&command->ICommandText_iface); +} + +static ULONG WINAPI cmd_with_params_Release(ICommandWithParameters *iface) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + return ICommandText_Release(&command->ICommandText_iface); +} + +static HRESULT WINAPI cmd_with_params_GetParameterInfo(ICommandWithParameters *iface, DB_UPARAMS *uparams, + DBPARAMINFO **info, OLECHAR **buffer) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + FIXME("%p, %p, %p, %p\n", command, uparams, info, buffer); + return E_NOTIMPL; +} + +static HRESULT WINAPI cmd_with_params_MapParameterNames(ICommandWithParameters *iface, DB_UPARAMS uparams, + LPCWSTR names[], DB_LPARAMS ordinals[]) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + FIXME("%p, %ld, %p, %p\n", command, uparams, names, ordinals); + return E_NOTIMPL; +} + +static HRESULT WINAPI cmd_with_params_SetParameterInfo(ICommandWithParameters *iface, DB_UPARAMS uparams, + const DB_UPARAMS ordinals[], const DBPARAMBINDINFO bindinfo[]) +{ + struct command *command = impl_from_ICommandWithParameters( iface ); + FIXME("%p, %ld, %p, %p\n", command, uparams, ordinals, bindinfo); + return E_NOTIMPL; +} + +struct ICommandWithParametersVtbl command_with_params_vtbl = +{ + cmd_with_params_QueryInterface, + cmd_with_params_AddRef, + cmd_with_params_Release, + cmd_with_params_GetParameterInfo, + cmd_with_params_MapParameterNames, + cmd_with_params_SetParameterInfo +}; + static HRESULT WINAPI createcommand_CreateCommand(IDBCreateCommand *iface, IUnknown *outer, REFIID riid, IUnknown **out) { @@ -1137,6 +1136,7 @@ static HRESULT WINAPI createcommand_CreateCommand(IDBCreateCommand *iface, IUnkn command->IColumnsInfo_iface.lpVtbl = &columninfoVtbl; command->IConvertType_iface.lpVtbl = &converttypeVtbl; command->ICommandPrepare_iface.lpVtbl = &commandprepareVtbl; + command->ICommandWithParameters_iface.lpVtbl = &command_with_params_vtbl; command->refs = 1; command->query = NULL;
Hi,
While running your changed tests, I think I found new failures. Being a bot and all I'm not very good at pattern recognition, so I might be wrong, but could you please double-check?
Full results can be found at: https://testbot.winehq.org/JobDetails.pl?Key=102091
Your paranoid android.
=== debiant2 (build log) ===
0050:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 0050:err:winediag:nodrv_CreateWindow Unknown error (998). 002c:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 002c:err:winediag:nodrv_CreateWindow Unknown error (998). 0048:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 0048:err:winediag:nodrv_CreateWindow Unknown error (998). 0040:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 0040:err:winediag:nodrv_CreateWindow Unknown error (998). 007c:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 007c:err:winediag:nodrv_CreateWindow Unknown error (998). 00c0:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 00c0:err:winediag:nodrv_CreateWindow Unknown error (998). 0050:err:winediag:nodrv_CreateWindow Application tried to create a window, but no driver could be loaded. 0050:err:winediag:nodrv_CreateWindow Unknown error (998). Error: Mount manager not running, most likely your WINEPREFIX wasn't created correctly. Task: WineTest did not produce the wow32 report