Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
N
nx-libs
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
1
Issues
1
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
dimbor
nx-libs
Commits
f1f2a360
You need to sign in or sign up before continuing.
Commit
f1f2a360
authored
Jan 22, 2018
by
Ulrich Sibiller
Committed by
Mihai Moldovan
Feb 26, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
dbe: add NXAGENT_SERVER guard for DixLookup
parent
d364ea93
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
0 deletions
+32
-0
Imakefile
nx-X11/programs/Xserver/dbe/Imakefile
+8
-0
dbe.c
nx-X11/programs/Xserver/dbe/dbe.c
+24
-0
No files found.
nx-X11/programs/Xserver/dbe/Imakefile
View file @
f1f2a360
...
@@ -6,6 +6,14 @@
...
@@ -6,6 +6,14 @@
INCLUDES = -I$(SERVERSRC)/include -I$(XINCLUDESRC) -I$(EXTINCSRC) $(EXTRAINCLUDES) `pkg-config --cflags-only-I pixman-1`
INCLUDES = -I$(SERVERSRC)/include -I$(XINCLUDESRC) -I$(EXTINCSRC) $(EXTRAINCLUDES) `pkg-config --cflags-only-I pixman-1`
LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln
LINTLIBS = ../dix/llib-ldix.ln ../os/llib-los.ln
#if defined(NXAgentServer) && NXAgentServer
NX_DEFINES = -DNXAGENT_SERVER
#endif
DEFINES = \
$(NX_DEFINES) \
$(NULL)
NormalLibraryObjectRule()
NormalLibraryObjectRule()
NormalLibraryTarget(dbe,$(OBJS))
NormalLibraryTarget(dbe,$(OBJS))
...
...
nx-X11/programs/Xserver/dbe/dbe.c
View file @
f1f2a360
...
@@ -375,11 +375,17 @@ ProcDbeAllocateBackBufferName(ClientPtr client)
...
@@ -375,11 +375,17 @@ ProcDbeAllocateBackBufferName(ClientPtr client)
REQUEST_SIZE_MATCH
(
xDbeAllocateBackBufferNameReq
);
REQUEST_SIZE_MATCH
(
xDbeAllocateBackBufferNameReq
);
/* The window must be valid. */
/* The window must be valid. */
#ifndef NXAGENT_SERVER
status
=
dixLookupWindow
(
&
pWin
,
stuff
->
window
,
client
,
DixWriteAccess
);
if
(
status
!=
Success
)
return
status
;
#else
if
(
!
(
pWin
=
SecurityLookupWindow
(
stuff
->
window
,
client
,
if
(
!
(
pWin
=
SecurityLookupWindow
(
stuff
->
window
,
client
,
DixWriteAccess
)))
DixWriteAccess
)))
{
{
return
(
BadWindow
);
return
(
BadWindow
);
}
}
#endif
/* The window must be InputOutput. */
/* The window must be InputOutput. */
if
(
pWin
->
drawable
.
class
!=
InputOutput
)
if
(
pWin
->
drawable
.
class
!=
InputOutput
)
...
@@ -704,12 +710,21 @@ ProcDbeSwapBuffers(ClientPtr client)
...
@@ -704,12 +710,21 @@ ProcDbeSwapBuffers(ClientPtr client)
/* Check all windows to swap. */
/* Check all windows to swap. */
/* Each window must be a valid window - BadWindow. */
/* Each window must be a valid window - BadWindow. */
#ifndef NXAGENT_SERVER
error
=
dixLookupWindow
(
&
pWin
,
dbeSwapInfo
[
i
].
window
,
client
,
DixWriteAccess
);
if
(
error
!=
Success
)
{
free
(
swapInfo
);
return
error
;
}
#else
if
(
!
(
pWin
=
SecurityLookupWindow
(
dbeSwapInfo
[
i
].
window
,
client
,
if
(
!
(
pWin
=
SecurityLookupWindow
(
dbeSwapInfo
[
i
].
window
,
client
,
DixWriteAccess
)))
DixWriteAccess
)))
{
{
free
(
swapInfo
);
free
(
swapInfo
);
return
(
BadWindow
);
return
(
BadWindow
);
}
}
#endif
/* Each window must be double-buffered - BadMatch. */
/* Each window must be double-buffered - BadMatch. */
if
(
DBE_WINDOW_PRIV
(
pWin
)
==
NULL
)
if
(
DBE_WINDOW_PRIV
(
pWin
)
==
NULL
)
...
@@ -867,12 +882,21 @@ ProcDbeGetVisualInfo(ClientPtr client)
...
@@ -867,12 +882,21 @@ ProcDbeGetVisualInfo(ClientPtr client)
for
(
i
=
0
;
i
<
stuff
->
n
;
i
++
)
for
(
i
=
0
;
i
<
stuff
->
n
;
i
++
)
{
{
#ifndef NXAGENT_SERVER
register
int
rc
=
dixLookupDrawable
(
pDrawables
+
i
,
drawables
[
i
],
client
,
0
,
DixReadAccess
);
if
(
rc
!=
Success
)
{
free
(
pDrawables
);
return
rc
;
}
#else
if
(
!
(
pDrawables
[
i
]
=
(
DrawablePtr
)
SecurityLookupDrawable
(
if
(
!
(
pDrawables
[
i
]
=
(
DrawablePtr
)
SecurityLookupDrawable
(
drawables
[
i
],
client
,
DixReadAccess
)))
drawables
[
i
],
client
,
DixReadAccess
)))
{
{
free
(
pDrawables
);
free
(
pDrawables
);
return
(
BadDrawable
);
return
(
BadDrawable
);
}
}
#endif
}
}
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment