November 18, 2013

C code to detect link connected/disconnected using RTNETLINK

RTNETLINK documentation is not very good. Here is an example of how to detect interface disconnected/disconnected using it. If you want to detect interface up and down, just check the flag IFF_UP instead of IFF_RUNNING.

1 comment:

  1. includes seem to be gobbled up...