提交 96ebb4fe 编写于 作者: P Peter Krempa

network_conf: Don't free uninitialized pointers while parsing DNS SRV

If the user specified invalid protocol type in a network's SRV record
the error path ended up in freeing uninitialized pointers causing a
daemon crash.

*network_conf.c: virNetworkDNSSrvDefParseXML(): initialize local
                                                variables
上级 6117c358
......@@ -574,10 +574,10 @@ virNetworkDNSSrvDefParseXML(virNetworkDNSDefPtr def,
xmlNodePtr cur,
xmlXPathContextPtr ctxt)
{
char *domain;
char *service;
char *protocol;
char *target;
char *domain = NULL;
char *service = NULL;
char *protocol = NULL;
char *target = NULL;
int port;
int priority;
int weight;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册