mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-17 23:05:11 +00:00
zebra: Remove strcpy from fast path
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
This commit is contained in:
parent
a57103e963
commit
7649a4f60c
@ -30,6 +30,7 @@
|
||||
#include "zebra/zebra_vrf.h"
|
||||
#include "zebra/zebra_mroute.h"
|
||||
#include "zebra/rt.h"
|
||||
#include "zebra/debug.h"
|
||||
|
||||
int zebra_ipmr_route_stats(struct zserv *client, int fd, u_short length,
|
||||
struct zebra_vrf *zvrf)
|
||||
@ -38,17 +39,21 @@ int zebra_ipmr_route_stats(struct zserv *client, int fd, u_short length,
|
||||
struct stream *s;
|
||||
int suc;
|
||||
|
||||
char sbuf[40];
|
||||
char gbuf[40];
|
||||
|
||||
memset(&mroute, 0, sizeof(mroute));
|
||||
stream_get(&mroute.sg.src, client->ibuf, 4);
|
||||
stream_get(&mroute.sg.grp, client->ibuf, 4);
|
||||
mroute.ifindex = stream_getl(client->ibuf);
|
||||
|
||||
if (IS_ZEBRA_DEBUG_KERNEL) {
|
||||
char sbuf[40];
|
||||
char gbuf[40];
|
||||
|
||||
strcpy(sbuf, inet_ntoa(mroute.sg.src));
|
||||
strcpy(gbuf, inet_ntoa(mroute.sg.grp));
|
||||
|
||||
zlog_debug("Asking for (%s,%s) mroute information", sbuf, gbuf);
|
||||
}
|
||||
|
||||
suc = kernel_get_ipmr_sg_stats(&mroute);
|
||||
|
||||
s = client->obuf;
|
||||
|
Loading…
Reference in New Issue
Block a user