Fix X -keepPriv by calling xf86OpenConsole() early enough on architectures
that don't have a separate /dev/xf86. Problem noticed by kettenis@ and krw@ ok kettenis@.
This commit is contained in:
parent
36733264e6
commit
fe603b97cb
@ -170,11 +170,9 @@ xf86OpenConsole()
|
|||||||
vtmode_t vtmode;
|
vtmode_t vtmode;
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#ifdef X_PRIVSEP
|
|
||||||
if (xf86Info.consoleFd != -1) {
|
if (xf86Info.consoleFd != -1) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
#endif
|
|
||||||
if (serverGeneration == 1)
|
if (serverGeneration == 1)
|
||||||
{
|
{
|
||||||
/* check if we are run with euid==0 */
|
/* check if we are run with euid==0 */
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
/* $OpenBSD: hppa_video.c,v 1.2 2009/12/18 22:47:56 matthieu Exp $ */
|
/* $OpenBSD: hppa_video.c,v 1.3 2010/07/31 17:47:50 matthieu Exp $ */
|
||||||
/*
|
/*
|
||||||
* Copyright 1992 by Rich Murphey <Rich@Rice.edu>
|
* Copyright 1992 by Rich Murphey <Rich@Rice.edu>
|
||||||
* Copyright 1993 by David Wexelblat <dwex@goblin.org>
|
* Copyright 1993 by David Wexelblat <dwex@goblin.org>
|
||||||
@ -51,6 +51,8 @@ static void hppaUnmapVidMem(int, pointer, unsigned long);
|
|||||||
void
|
void
|
||||||
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
||||||
{
|
{
|
||||||
|
xf86OpenConsole();
|
||||||
|
|
||||||
pVidMem->linearSupported = TRUE;
|
pVidMem->linearSupported = TRUE;
|
||||||
pVidMem->mapMem = hppaMapVidMem;
|
pVidMem->mapMem = hppaMapVidMem;
|
||||||
pVidMem->unmapMem = hppaUnmapVidMem;
|
pVidMem->unmapMem = hppaUnmapVidMem;
|
||||||
|
@ -62,6 +62,8 @@ void xf86DisableIO(void);
|
|||||||
void
|
void
|
||||||
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
||||||
{
|
{
|
||||||
|
xf86OpenConsole();
|
||||||
|
|
||||||
pVidMem->linearSupported = TRUE;
|
pVidMem->linearSupported = TRUE;
|
||||||
pVidMem->mapMem = ppcMapVidMem;
|
pVidMem->mapMem = ppcMapVidMem;
|
||||||
pVidMem->unmapMem = ppcUnmapVidMem;
|
pVidMem->unmapMem = ppcUnmapVidMem;
|
||||||
|
@ -48,6 +48,8 @@ static void sparc64UnmapVidMem(int, pointer, unsigned long);
|
|||||||
void
|
void
|
||||||
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
xf86OSInitVidMem(VidMemInfoPtr pVidMem)
|
||||||
{
|
{
|
||||||
|
xf86OpenConsole();
|
||||||
|
|
||||||
pVidMem->linearSupported = TRUE;
|
pVidMem->linearSupported = TRUE;
|
||||||
pVidMem->mapMem = sparc64MapVidMem;
|
pVidMem->mapMem = sparc64MapVidMem;
|
||||||
pVidMem->unmapMem = sparc64UnmapVidMem;
|
pVidMem->unmapMem = sparc64UnmapVidMem;
|
||||||
|
Loading…
Reference in New Issue
Block a user