The problem is only when compiling with autotools. With cmake the bin extcap dir is clean and it doesn't affect startup time. Btw the check you added is wise and should be done anyway in case unwanted artifacts are there. The problem with extcaps is that androiddump is the only tool that enumerates interfaces at start time. Others have static interfaces and start very quickly. Me, Michal and others have discussed a lot on this topic but we didn't find a final answer. At the moment there is a timeout of 4s to allow androiddump to connect to ADB. If ADB is not running, we wait until the timeout, and it's pretty annoying if you don't have adb and will never have, imho.
A faster solution would be to check if the process adb is running and if it's not, just skip the attempt. But we didn't find a suitable way to do so on unix & windows. A possible solution could be to run this check on systems that support the choosen method (like kill described here http://stackoverflow.com/questions/6898337/determine-programmatically-if-a-program-is-running), and skip it on windows, leaving the things as they are right now. Michal what do you think? On Mon, Mar 27, 2017 at 10:14 PM, Guy Harris <[email protected]> wrote: > On Mar 26, 2017, at 11:30 PM, Michał Łabędzki < > [email protected]> wrote: > > > Could you check if any of extcap binaries generates that delay? > > A lot of the delay comes from extcap *non*-binaries; the code that scans > the extcap directory tried running *everything* it finds there, except for > "." and "..", and, if you're running from the build directory, that means > executing somewhat heavyweight {fork/vfork}-exec calls on a bunch of source > files, object files, .deps directories, Makefiles, etc.. > > bd3196b094ae46fa4396edbb406d68056cba6974 fixed that. > > Currently, with that fix, I get results like > > $ time ./tshark -r /tmp/nothing.pcap > > real 0m1.407s > user 0m0.312s > sys 0m0.676s > > with the extcap directory in place and results like > > $ time ./tshark -r /tmp/nothing.pcap > > real 0m0.334s > user 0m0.182s > sys 0m0.146s > > with the extcap directory moved out of the way, so the extcap executables > are taking some time to run, but it's better than wasting time trying to > run androiddump.c or Makefile.am. > ____________________________________________________________ > _______________ > Sent via: Wireshark-dev mailing list <[email protected]> > Archives: https://www.wireshark.org/lists/wireshark-dev > Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev > mailto:[email protected]?subject= > unsubscribe
___________________________________________________________________________ Sent via: Wireshark-dev mailing list <[email protected]> Archives: https://www.wireshark.org/lists/wireshark-dev Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev mailto:[email protected]?subject=unsubscribe
