[IRCServices Coding] svcs5

Finny Merrill griever at t2n.org
Fri Dec 21 11:51:00 PST 2001


On Sat, 22 Dec 2001, Andrew Church wrote:

> >this may try to free something that is not malloced (if i get this right)
> >when it is called from makechan() (free(NULL) works under glibc, but i do
> >n't
> >know how portable/standard it is)
> 
>      I'm pretty sure that's standard, and if it turns out not to be I'll
> just write my own free() because the rest of the code assumes it works
> that way.

ISO C guarantees free(NULL) is safe
> 
> >finaly in chanserv/access-levels.c, in do_levels():
> [snip]
> >the marked line is where i get the coredump...
> >it doesn't make any sense.. 
> >if ci->levels is NULL, then reset_levels is not called...
> >so it remains NULL and then ci->levels[] is used
> 
>      The test on ci->levels was backwards in sense.  Fixed, thanks.
> 
>   --Andrew Church
>     achurch at achurch.org
>     http://achurch.org/
> ------------------------------------------------------------------
> To unsubscribe or change your subscription options, visit:
> http://www.ircservices.za.net/mailman/listinfo/ircservices-coding
>