stop client_dns_clean from calling malloc(0)

svn:r831
This commit is contained in:
Roger Dingledine 2003-11-18 00:02:24 +00:00
parent 4eabb8450e
commit 51de02bcb5

View File

@ -902,6 +902,8 @@ void client_dns_clean(void)
time_t now;
int i;
if(!client_dns_size)
return;
expired_entries = tor_malloc(client_dns_size *
sizeof(struct client_dns_entry *));