No that's kinda C++. He doesn't typedef the struct the whole time, malloc/realloc is legal and he casts it. Problem:
Code:
listptr->URL = (char*)malloc(strlen(data)+1);
listptr->URL = data;
listptr->URL = (char*)realloc(listptr->URL, strlen(data)+1);
You allocate memory, then reassign the pointer (memory leak), and then try to realloc something that wasn't originally allocated with realloc/malloc/calloc or is NULL, so it prolly crashes.
Code:
listptr->URL = (char*) malloc(strlen(data)+1);
strcpy(listptr->URL, data);
listptr->URL = (char*)realloc(listptr->URL, strlen(data)+1); // Block is the same size still...