Commit c0f7009b authored by Jan Kiszka's avatar Jan Kiszka

demo/posix/cobalt: Avoid ancillaries header

Makes the demo more portable.
Signed-off-by: Jan Kiszka's avatarJan Kiszka <>
parent c70bee54
......@@ -40,7 +40,6 @@
#include <net/if.h>
#include <arpa/inet.h>
#include <netinet/ether.h>
#include <boilerplate/ancillaries.h>
char buffer[10*1024];
int sock;
......@@ -73,7 +72,7 @@ int main(int argc, char *argv[])
if (argc > 1) {
struct ifreq ifr;
namecpy(ifr.ifr_name, argv[1]);
snprintf(ifr.ifr_name, IFNAMSIZ, "%s", argv[1]);
if (ioctl(sock, SIOCGIFINDEX, &ifr) < 0) {
perror("cannot get interface index");
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment