On quinta-feira, 11 de agosto de 2016 16:18:22 PDT André Hartmann wrote: > Hi Edward, > > > How hard would it be to teach QNetworkInterface how to detect > > CAN-iness in the interfaces it's clearly able to enumerate ? > > I'm currently trying to find this out. What I know so far, is that > you can compare "something" to > > #define ARPHRD_CAN 280 > > to find out the interface is of type SocketCAN. As there are more of > these definitions in /usr/include/linux/if_arp.h, a generic way to get > the "type" of an interface could be added to QNetworkInterface. > > Maybe someone with more Linux programming knowlegde has a hint - > libenumif surely knows it, but looks like a sledgehammer for my small > problem.
I have a preliminary patch that detects the interface type in QNetworkInterface. Just pushed at https://codereview.qt-project.org/167772. -- Thiago Macieira - thiago.macieira (AT) intel.com Software Architect - Intel Open Source Technology Center _______________________________________________ Development mailing list Development@qt-project.org http://lists.qt-project.org/mailman/listinfo/development