mirror of https://github.com/getdnsapi/getdns.git
Fix for issue #67. return INVALID_PARAMETER if name, dict, or child dict are NULL
This commit is contained in:
parent
2c664e73fe
commit
34d3f1f938
|
@ -370,8 +370,8 @@ getdns_dict_set_dict(struct getdns_dict * dict, char *name,
|
||||||
struct getdns_dict *newdict;
|
struct getdns_dict *newdict;
|
||||||
getdns_return_t retval;
|
getdns_return_t retval;
|
||||||
|
|
||||||
if (!dict || !name)
|
if (!dict || !name || !child_dict)
|
||||||
return GETDNS_RETURN_NO_SUCH_DICT_NAME;
|
return GETDNS_RETURN_INVALID_PARAMETER;
|
||||||
|
|
||||||
retval = getdns_dict_copy(child_dict, &newdict);
|
retval = getdns_dict_copy(child_dict, &newdict);
|
||||||
if (retval != GETDNS_RETURN_GOOD)
|
if (retval != GETDNS_RETURN_GOOD)
|
||||||
|
|
Loading…
Reference in New Issue