+ hdr.length -= ZEBRA_HEADER_SIZE;
+
+ /* lookup vrf */
+ zvrf = zebra_vrf_lookup_by_id(hdr.vrf_id);
+ if (!zvrf) {
+ if (IS_ZEBRA_DEBUG_PACKET && IS_ZEBRA_DEBUG_RECV)
+ zlog_warn("ZAPI message specifies unknown VRF: %d",
+ hdr.vrf_id);
+ return;
+ }
+
+ if (hdr.command > array_size(zserv_handlers)
+ || zserv_handlers[hdr.command] == NULL)
+ zlog_info("Zebra received unknown command %d", hdr.command);
+ else
+ zserv_handlers[hdr.command](client, &hdr, msg, zvrf);