From: Vibhav Pant vibhavp@gmail.com
--- dlls/bluetoothapis/main.c | 21 +++++++++++++++++---- 1 file changed, 17 insertions(+), 4 deletions(-)
diff --git a/dlls/bluetoothapis/main.c b/dlls/bluetoothapis/main.c index 727d13118f5..df7cd57e9b1 100644 --- a/dlls/bluetoothapis/main.c +++ b/dlls/bluetoothapis/main.c @@ -605,11 +605,24 @@ BOOL WINAPI BluetoothEnableDiscovery( HANDLE radio, BOOL enabled ) /********************************************************************* * BluetoothFindNextDevice */ -BOOL WINAPI BluetoothFindNextDevice(HBLUETOOTH_DEVICE_FIND find, BLUETOOTH_DEVICE_INFO *info) +BOOL WINAPI BluetoothFindNextDevice( HBLUETOOTH_DEVICE_FIND find, BLUETOOTH_DEVICE_INFO *info ) { - FIXME("(%p, %p): stub!\n", find, info); - SetLastError(ERROR_CALL_NOT_IMPLEMENTED); - return FALSE; + BOOL success; + + TRACE( "(%p, %p)\n", find, info ); + + /* This method doesn't perform any validation for info, for some reason. */ + if (!find) + { + SetLastError( ERROR_INVALID_HANDLE ); + return FALSE; + } + + success = device_find_set_next( find, info ); + if (!success) + SetLastError( ERROR_NO_MORE_ITEMS ); + + return success; }
/*********************************************************************