mirror of
https://github.com/X11Libre/xserver.git
synced 2026-03-26 06:04:49 +00:00
Turn sprintf argument into literaral string, shutting up gcc warning
Signed-off-by: Mikhail Gusarov <dottedmag@dottedmag.net> Reviewed-by: Matt Turner <mattst88@gmail.com>
This commit is contained in:
@@ -161,7 +161,6 @@ void
|
||||
OsInit(void)
|
||||
{
|
||||
static Bool been_here = FALSE;
|
||||
static char* admpath = ADMPATH;
|
||||
static char* devnull = "/dev/null";
|
||||
char fname[PATH_MAX];
|
||||
|
||||
@@ -229,8 +228,8 @@ OsInit(void)
|
||||
{
|
||||
FILE *err;
|
||||
|
||||
if (strlen (display) + strlen (admpath) + 1 < sizeof fname)
|
||||
sprintf (fname, admpath, display);
|
||||
if (strlen (display) + strlen (ADMPATH) + 1 < sizeof fname)
|
||||
sprintf (fname, ADMPATH, display);
|
||||
else
|
||||
strcpy (fname, devnull);
|
||||
/*
|
||||
|
||||
Reference in New Issue
Block a user