I have a type queue_t, its a head of a linked list. Then I have these variables:
They are arrays of 15 elements, where each element is a pointer to queue_t (Pretty obvious).
So far so good. Now I want to make a function to swich them. What I mean is:
what ever exe_thr_list points to must (after the function is called) point to whaever expired_thr_list points to. And vice versa. In other words to swich the two arrays.
I made this obviously wrong code:
Wrong because I can't compile it with gcc, getting the following error:Code:queue_t *tmp_queue; tmp_queue = exe_thr_list; exe_thr_list = expired_thr_list; expired_thr_list = tmp_queue;
error: incompatible types in assignment
in the last three lines of code.
Can someone point me to the light (LOOOL)??