bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH 2/6] kern/lock.h: quiet GCC warnings about set but unused var


From: Marin Ramesa
Subject: Re: [PATCH 2/6] kern/lock.h: quiet GCC warnings about set but unused variables
Date: Sun, 15 Dec 2013 20:50:32 +0100

On 15.12.2013 20:13:22, Samuel Thibault wrote: 
> > index 8fe3672..67067cf 100644
> > --- a/kern/task.c
> > +++ b/kern/task.c
> > @@ -769,7 +769,7 @@ kern_return_t task_info(
> >             event_info->cow_faults = task->cow_faults;
> >             event_info->messages_sent = task->messages_sent;
> >             event_info->messages_received =
> > task->messages_received;
> > -           task_unlock(&task);
> > +           task_unlock(task);
> 
> Err, this is not the same at all, while task_lock is still using
> &task. Either both need the fix, or none.

They both need the fix. This code won't compile when simple_lock() is 
an unempty macro or a function.


reply via email to

[Prev in Thread] Current Thread [Next in Thread]