X-Git-Url: http://git.droids-corp.org/?a=blobdiff_plain;f=drivers%2Fnet%2Fvirtio%2Fvirtio_user_ethdev.c;h=e85906e9eb09ff808eac3239b5350487c708d6f7;hb=21b1677d87a23a9695be0cbcbdf38607a2d58f84;hp=79bd31ed821b7974b91802d32254736bdae3aada;hpb=6564ddcd0cbfcc3bb0acacbbc0f1247eb52ad218;p=dpdk.git diff --git a/drivers/net/virtio/virtio_user_ethdev.c b/drivers/net/virtio/virtio_user_ethdev.c index 79bd31ed82..e85906e9eb 100644 --- a/drivers/net/virtio/virtio_user_ethdev.c +++ b/drivers/net/virtio/virtio_user_ethdev.c @@ -360,7 +360,7 @@ vdpa_dynamic_major_num(void) { FILE *fp; char *line = NULL; - size_t size; + size_t size = 0; char name[11]; bool found = false; uint32_t num; @@ -380,6 +380,7 @@ vdpa_dynamic_major_num(void) break; } } + free(line); fclose(fp); return found ? num : UNNAMED_MAJOR; }