mirror of
https://github.com/X11Libre/xserver.git
synced 2026-09-20 20:12:21 +00:00
Convert a bunch of sprintf to snprintf calls
This batch is the straightforward set - others are more complex and need more analysis to determine right size to pass. Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
This commit is contained in:
parent
b967bf2af2
commit
05d8a7f7a7
20 changed files with 119 additions and 115 deletions
|
|
@ -213,7 +213,7 @@ OsInit(void)
|
|||
FILE *err;
|
||||
|
||||
if (strlen (display) + strlen (ADMPATH) + 1 < sizeof fname)
|
||||
sprintf (fname, ADMPATH, display);
|
||||
snprintf (fname, sizeof(fname), ADMPATH, display);
|
||||
else
|
||||
strcpy (fname, devnull);
|
||||
/*
|
||||
|
|
|
|||
Loading…
Reference in a new issue