mirror of
https://github.com/libretro/RetroArch.git
synced 2026-11-07 08:36:02 -10:00
Silence warning about possible truncation
Also simplify this part; the point here is to start the copy later, but otherwise the buffer size is the same, and it's still a string, so needs no special handling.
This commit is contained in:
1 parent
b85bcb8e48
commit
3fb7d190bf
1 file changed
+1
-2
@@ -722,8 +722,7 @@ int detect_sat_game(intfstream_t *fd, char *s, size_t len, const char *filename)
|
||||
&& raw_game_id[1] == 'K'
|
||||
&& raw_game_id[2] == '-')
|
||||
{
|
||||
strncpy(s, &raw_game_id[3], __len - 3);
|
||||
s[__len - 3] = '\0';
|
||||
strlcpy(s, &raw_game_id[3], len);
|
||||
}
|
||||
else
|
||||
strlcpy(s, raw_game_id, len);
|
||||
|
||||
Reference in new issue
Block a user