The error message is clear enough: you are passing struct auth ** where void ** was accepted. There is no implicit conversion between these types, since void* may not have the same size and alignment as other types of pointers.
The solution is to use an intermediate void* :
void *current_void; struct auth *current; gl_list_iterator_next(&it, ¤t_void, NULL); current = current_void;
EDIT : To answer the comments below, here is an example of why this is necessary. Suppose you are on a platform where sizeof(struct auth*) == sizeof(short) == 2 , and sizeof(void*) == sizeof(long) == 4 ; as allowed by the C standard and platforms with different sizes of pointers. Then the OP code will be like running
short current; long *p = (long *)(¤t);
However, this program can also be made to work by entering an intermediate long (although the result may only make sense when the long value is small enough to be stored in short ).
source share