whoozle / android-file-transfer-linux

Android File Transfer for Linux (and macOS!)
http://whoozle.github.io/android-file-transfer-linux/
GNU Lesser General Public License v2.1
1.47k stars 120 forks source link

Bug (?) in Device::FindFirst() #333

Closed kirillnow closed 1 year ago

kirillnow commented 1 year ago

Going by the code of this function, aft-mtp-mount should support filtering devices by "vendor:product". Example: aft-mtp-mount -D 0e8d:2008 /tmp/mtp It is a very useful feature for other script and apps. But to do so, the following line if (device && device->Matches(filter)) should be changed to if (device && ((vendor >= 0 && product >= 0) || device->Matches(filter)))

whoozle commented 1 year ago

fixed in a9495bfd712a72011449af6a6d40bc4fc41592e4 Thank you for reporting this!