On Thu, 2007-05-24 at 17:31 +0200, Johan Hedberg wrote: > Hi Bastien, > > On May 24, 2007, at 15:39, Bastien Nocera wrote: > > On Wed, 2007-05-23 at 18:56 +0200, Johan Hedberg wrote: > >> Hi Bastien, > >> > >> On May 23, 2007, at 18:26, Bastien Nocera wrote: > >>> Updated patch attached. > >> > >> A little about optimizing the device discovery. > > > > Fixed in this version, and also added recent devices (through > > ListRemoteDevices and ListBondings). > > I see you're now using the manual name resolving discovery and > deciding from the device class whether to get the name or not. Great! > However, you are causing an unecessary roundtrip back to hcid by > calling GetRemoteMinorClass because you in fact already have the > necessary information encoded in the class parameter of the > RemoteDeviceFound signal. It's not as convenient as a string to do a > strcmp on, but you can just take example from hcid code how it > converts the 3 byte value to the string. This is most ugly. There should really be a helper function for that, or hcid should pass a decoded argument. Anyway, it's implemented now, along with a port to pure D-Bus, and can use the builtin eglib instead of the system one. Marcel -- Bastien Nocera