Commit ab6bb890 authored by Mike Gabriel's avatar Mike Gabriel

hw/nxagent/NXresource.c: Shrink file, drop duplicate code that can identically…

hw/nxagent/NXresource.c: Shrink file, drop duplicate code that can identically be found in dix/resource.c.
parent 1384776f
...@@ -16,10 +16,12 @@ FFS_OBJ = ffs.o ...@@ -16,10 +16,12 @@ FFS_OBJ = ffs.o
#if (!(defined(NXAgentServer) && NXAgentServer)) #if (!(defined(NXAgentServer) && NXAgentServer))
NXAGENT_SKIP_SRCS = \ NXAGENT_SKIP_SRCS = \
extension.c \ extension.c \
resource.c \
window.c \ window.c \
$(NULL) $(NULL)
NXAGENT_SKIP_OBJS = \ NXAGENT_SKIP_OBJS = \
extension.o \ extension.o \
resource.o \
window.o \ window.o \
$(NULL) $(NULL)
#endif #endif
...@@ -40,7 +42,6 @@ SRCS = \ ...@@ -40,7 +42,6 @@ SRCS = \
main.c \ main.c \
property.c \ property.c \
region.c \ region.c \
resource.c \
swaprep.c \ swaprep.c \
swapreq.c \ swapreq.c \
tables.c \ tables.c \
...@@ -67,7 +68,6 @@ OBJS = \ ...@@ -67,7 +68,6 @@ OBJS = \
main.o \ main.o \
property.o \ property.o \
region.o \ region.o \
resource.o \
swaprep.o \ swaprep.o \
swapreq.o \ swapreq.o \
tables.o \ tables.o \
......
...@@ -422,6 +422,7 @@ FakeClientID(register int client) ...@@ -422,6 +422,7 @@ FakeClientID(register int client)
return id; return id;
} }
#ifndef NXAGENT_SERVER
Bool Bool
AddResource(XID id, RESTYPE type, void * value) AddResource(XID id, RESTYPE type, void * value)
{ {
...@@ -457,6 +458,7 @@ AddResource(XID id, RESTYPE type, void * value) ...@@ -457,6 +458,7 @@ AddResource(XID id, RESTYPE type, void * value)
rrec->expectID = id + 1; rrec->expectID = id + 1;
return TRUE; return TRUE;
} }
#endif /* NXAGENT_SERVER */
static void static void
RebuildTable(int client) RebuildTable(int client)
...@@ -507,6 +509,7 @@ RebuildTable(int client) ...@@ -507,6 +509,7 @@ RebuildTable(int client)
clientTable[client].resources = resources; clientTable[client].resources = resources;
} }
#ifndef NXAGENT_SERVER
void void
FreeResource(XID id, RESTYPE skipDeleteFuncType) FreeResource(XID id, RESTYPE skipDeleteFuncType)
{ {
...@@ -573,6 +576,7 @@ FreeResourceByType(XID id, RESTYPE type, Bool skipFree) ...@@ -573,6 +576,7 @@ FreeResourceByType(XID id, RESTYPE type, Bool skipFree)
} }
} }
} }
#endif /* NXAGENT_SERVER */
/* /*
* Change the value associated with a resource id. Caller * Change the value associated with a resource id. Caller
...@@ -606,6 +610,7 @@ ChangeResourceValue (XID id, RESTYPE rtype, void * value) ...@@ -606,6 +610,7 @@ ChangeResourceValue (XID id, RESTYPE rtype, void * value)
* add and delete an equal number of resources! * add and delete an equal number of resources!
*/ */
#ifndef NXAGENT_SERVER
void void
FindClientResourcesByType( FindClientResourcesByType(
ClientPtr client, ClientPtr client,
...@@ -693,6 +698,7 @@ LookupClientResourceComplex( ...@@ -693,6 +698,7 @@ LookupClientResourceComplex(
} }
return NULL; return NULL;
} }
#endif /* NXAGENT_SERVER */
void void
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment