Use only safe string functions
--HG-- extra : convert_revision : svn%3Ac70aab31-4412-0410-b14c-859654838e24/trunk%401383
This commit is contained in:
parent
a81db3ea34
commit
1da8cb0143
60 changed files with 223 additions and 263 deletions
|
@ -373,8 +373,7 @@ int SDL_AudioInit(const char *driver_name)
|
|||
char *SDL_AudioDriverName(char *namebuf, int maxlen)
|
||||
{
|
||||
if ( current_audio != NULL ) {
|
||||
SDL_strncpy(namebuf, current_audio->name, maxlen-1);
|
||||
namebuf[maxlen-1] = '\0';
|
||||
SDL_strlcpy(namebuf, current_audio->name, maxlen);
|
||||
return(namebuf);
|
||||
}
|
||||
return(NULL);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue