|
@@ -111,12 +111,13 @@ static void clearint(car * done)
|
|
|
}
|
|
|
|
|
|
active->front = active->front->next;
|
|
|
- goto SKIP1;
|
|
|
+ }
|
|
|
+ else
|
|
|
+ {
|
|
|
+ // we are removing the middle or end, so we can set the previous to point to the element after the removed
|
|
|
+ temp2->next = temp->next;
|
|
|
}
|
|
|
|
|
|
- temp2->next = temp->next;
|
|
|
- SKIP1:
|
|
|
-
|
|
|
if (temp->cv) // if this car was blocking something
|
|
|
{
|
|
|
cv_broadcast(temp->cv, globlock); // wake all/inform them you're all good
|