chiark / gitweb /
sd-rtnl: add sd_rtnl_message_{new_neigh,neigh_get_{family,ifindex}}
[elogind.git] / src / libsystemd / sd-rtnl / rtnl-util.c
index 4521742b8e9a78e51cebdf1a16ff95b78894fb8e..194a267b04b88af126235ee2f63a17a9035871f7 100644 (file)
@@ -122,6 +122,17 @@ int rtnl_message_new_synthetic_error(int error, uint32_t serial, sd_rtnl_message
         return 0;
 }
 
+bool rtnl_message_type_is_neigh(uint16_t type) {
+        switch (type) {
+                case RTM_NEWNEIGH:
+                case RTM_GETNEIGH:
+                case RTM_DELNEIGH:
+                        return true;
+                default:
+                        return false;
+        }
+}
+
 bool rtnl_message_type_is_route(uint16_t type) {
         switch (type) {
                 case RTM_NEWROUTE: