Hi, On 03/20/2013 02:16 AM, Xiaofan Chen wrote: > On Wed, Mar 20, 2013 at 6:43 AM, Pete Batard <p...@akeo.ie> wrote: >> Oh, and for what is worth, I think over at libusb we discussed the idea >> of having a _detach() call that did nothing but returned success on >> Windows, to avoid #ifdefs, but that idea was rejected at the time. I >> think I proposed a patch for that actually. > > Actually I think this is probably the way to go. Documenting that > the _detach call is only functional under Linux and does nothing > for other OS (just return success).
No please, in practice for 90+ % of all devices we need to get the native driver out of the way, currently we only support doing so under Linux, and it must be done through other means then libusbx on other platforms. Just because it needs to be done through other means does not mean that it is not necessary. No lets say we go and just make the call return success on other platforms, without it actually doing something. And then one day we get a nice patchset for Darwin to actually implement it properly, then how can apps test whether or not they have an actually working _detach() call ? Since detach is something which is needed on other platforms too, we might one day actually get it, and therefor it should keep returning an error on other platforms, so that once we do get it apps can check whether they are running on a version of libusbx which implements it or not. Regards, Hans ------------------------------------------------------------------------------ Everyone hates slow websites. So do we. Make your web apps faster with AppDynamics Download AppDynamics Lite for free today: http://p.sf.net/sfu/appdyn_d2d_mar _______________________________________________ libusbx-devel mailing list libusbx-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/libusbx-devel