read_line() always null-terminates string

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@2481 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Björn Stenberg 2002-10-02 18:28:38 +00:00
parent bde60b66d1
commit 51159b0e8c

View file

@ -483,6 +483,8 @@ static int read_line(int fd, char* buffer, int buffer_size)
if ( count < buffer_size )
buffer[count] = 0;
else
buffer[buffer_size-1] = 0;
return count;
}