DragonFly BSD
DragonFly commits List (threaded) for 2004-11
[Date Prev][Date Next]  [Thread Prev][Thread Next]  [Date Index][Thread Index]

Re: cvs commit: src/bin/ps


From: YONETANI Tomokazu <qhwt+dfly@xxxxxxxxxx>
Date: Mon, 15 Nov 2004 22:59:18 +0900

On Sun, Nov 14, 2004 at 05:58:42AM -0800, Eirik Nygaard wrote:
> eirikn      2004/11/14 05:58:42 PST
> 
> DragonFly src repository
> 
>   Modified files:
>     bin/ps               Makefile extern.h keyword.c print.c 
>   Log:
>   Constify VAR.
>   
>   Submitted by: joerg
>   
>   WARNS=6 cleanup.
>   
>   Revision  Changes    Path
>   1.3       +3 -1      src/bin/ps/Makefile
>   1.8       +1 -1      src/bin/ps/extern.h
>   1.13      +118 -107  src/bin/ps/keyword.c
>   1.16      +1 -1      src/bin/ps/print.c

No, you can't do this constification yet. Try `ps u' and it catches
SIGBUS because scanvars() tries to write to a member of var[].
The reason you aren't seeing warning from the compiler is because bsearch()
returns void * even though it's passed const void * as its second argument.



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