A void *indicates data of an unknown type (if it is initialized, but yours is not).
You can only assign variables of a known type or through pointers of a known type.
int p = 10;
void *q = &p;
*(int *)q = 20;
if (p != 20)
...something has gone horribly wrong...
This converts void *to int *and then assigns a value to this dereferenced integer pointer.
source
share