]> git.proxmox.com Git - mirror_iproute2.git/blobdiff - tc/m_mirred.c
utils: Introduce and use nodev() helper routine
[mirror_iproute2.git] / tc / m_mirred.c
index eb42b7c13bec75bab75469f2efd7081ee1ad8ebe..b25b9acc0735e872b42e65013e8fba23874f3fdb 100644 (file)
@@ -193,10 +193,8 @@ parse_direction(struct action_util *a, int *argc_p, char ***argv_p,
                ll_init_map(&rth);
 
                idx = ll_name_to_index(d);
-               if (idx == 0) {
-                       fprintf(stderr, "Cannot find device \"%s\"\n", d);
-                       return -1;
-               }
+               if (!idx)
+                       return nodev(d);
 
                p.ifindex = idx;
        }