Rockbox mail archiveSubject: Re: cvs: apps settings.c,1.67,1.68
From: Björn Stenberg (bjorn_at_haxx.se)
Magnus Holmgren wrote:
Yes. I removed that, since I think it should rather be handled in tree.c after the loading is completed.
> read_line was deliberately written to always null-terminate the buffer.
if ( count < buffer_size )
It null terminates, unless the string was completely filled. This is standard behaviour, just like strncpy etc. However, I'm inclined to agree with you that this can cause problems, since users of read_line (such as myself ;) will likely forget to check this.
Page was last modified "Jan 10 2012" The Rockbox Crew