The attached patch will fix this bug.

Tested with 0.91.2-1~volatile1

This fixes the crash on memcpy when the url is something like
"http:///";.

This is where the crash happens:
memcpy((char *)&ip, h.h_addr, sizeof(ip));

Cheers,

Daniel
--- mbox.c.2007122201	2007-12-22 12:57:14.026635484 +0100
+++ mbox.c	2007-12-22 13:49:56.913056383 +0100
@@ -4258,6 +4258,12 @@
 			return NULL;
 		}
 
+		if(strncasecmp(url, "http:///";, 8) == 0) {
+			cli_warnmsg("Invalid url: %s\n",url);
+			fclose(fp);
+			return NULL;
+		}
+
 		url += 7;
 		while(*url) {
 			if(doingsite && (*url == ':')) {

Reply via email to