From cbb842666fa7ff26bbdd1e89a7f41b835a677c5e Mon Sep 17 00:00:00 2001 From: Alexandr Shadchin Date: Fri, 26 Aug 2011 21:42:41 +0600 Subject: [PATCH] bsd: Variable devConsoleFd need only if defined PCCONS_SUPPORT Signed-off-by: Alexandr Shadchin Reviewed-by: Jamey Sharp Tested-by: Matthieu Herrb --- hw/xfree86/os-support/bsd/bsd_init.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/hw/xfree86/os-support/bsd/bsd_init.c b/hw/xfree86/os-support/bsd/bsd_init.c index f9d546f28..5f5008fee 100644 --- a/hw/xfree86/os-support/bsd/bsd_init.c +++ b/hw/xfree86/os-support/bsd/bsd_init.c @@ -41,7 +41,10 @@ #include static Bool KeepTty = FALSE; + +#ifdef PCCONS_SUPPORT static int devConsoleFd = -1; +#endif #if defined (SYSCONS_SUPPORT) || defined (PCVT_SUPPORT) static int VTnum = -1; static int initialVT = -1; @@ -694,8 +697,10 @@ xf86CloseConsole() } close(xf86Info.consoleFd); +#ifdef PCCONS_SUPPORT if (devConsoleFd >= 0) close(devConsoleFd); +#endif return; }