diff --git a/configure.ac b/configure.ac index d52127f9c..5003e241d 100644 --- a/configure.ac +++ b/configure.ac @@ -299,23 +299,6 @@ AC_DEFUN([DEFINE_CUDA], [ ]) AC_SUBST(DLL_LIBS) -if test $system = Windows -then - AC_MSG_CHECKING([if_nametoindex]) - AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[ - #include - #include - ]], [[ - if_nametoindex("eth");]] - )], HAVE_IF_NAMETOINDEX=yes, HAVE_IF_NAMETOINDEX=no) - AC_MSG_RESULT([$HAVE_IF_NAMETOINDEX]) - if test $HAVE_IF_NAMETOINDEX = yes; then - AC_DEFINE([HAVE_IF_TONAMEINDEX], 1, [Function if_nametoindex is present.]) - fi -else - AC_CHECK_FUNCS(if_nametoindex) -fi - AC_CHECK_FUNCS(usleep) AC_CHECK_FUNCS(strtok_r) AC_CHECK_FUNCS(timespec_get) diff --git a/src/rtp/net_udp.c b/src/rtp/net_udp.c index 810b4d650..5fb245103 100644 --- a/src/rtp/net_udp.c +++ b/src/rtp/net_udp.c @@ -810,14 +810,10 @@ socket_udp *udp_init_if(const char *addr, const char *iface, uint16_t rx_port, goto error; } if (iface != NULL) { -#ifdef HAVE_IF_NAMETOINDEX if ((s->ifindex = if_nametoindex(iface)) == 0) { - debug_msg("Illegal interface specification\n"); + error_msg("Illegal interface specification\n"); goto error; } -#else - log_msg(LOG_LEVEL_ERROR, "Cannot set interface name, if_nametoindex not supported.\n"); -#endif } else { s->ifindex = 0; }