queue.c modified