my_parse.c

00001 #include <netlink/msg.h>
00002 
00003 void my_parse(void *stream, int length)
00004 {
00005         struct nlmsghdr *hdr = stream;
00006 
00007         while (nlmsg_ok(hdr, length)) {
00008                 // Parse message here
00009                 hdr = nlmsg_next(hdr, &length);
00010         }
00011 }