Commit 0b625990 authored by Ulrich Sibiller's avatar Ulrich Sibiller Committed by Mihai Moldovan

Lift record to xorg-xserver-7.1/1.1.0 state - non-functional changes only

parent db836fd7
...@@ -202,8 +202,7 @@ static int numEnabledContexts; ...@@ -202,8 +202,7 @@ static int numEnabledContexts;
* Side Effects: none. * Side Effects: none.
*/ */
static int static int
RecordFindContextOnAllContexts(pContext) RecordFindContextOnAllContexts(RecordContextPtr pContext)
RecordContextPtr pContext;
{ {
int i; int i;
...@@ -466,10 +465,7 @@ RecordFindClientOnContext( ...@@ -466,10 +465,7 @@ RecordFindClientOnContext(
* Note: this function exists mainly to make RecordARequest smaller. * Note: this function exists mainly to make RecordARequest smaller.
*/ */
static void static void
RecordABigRequest(pContext, client, stuff) RecordABigRequest(RecordContextPtr pContext, ClientPtr client, xReq *stuff)
RecordContextPtr pContext;
ClientPtr client;
xReq *stuff;
{ {
CARD32 bigLength; CARD32 bigLength;
int bytesLeft; int bytesLeft;
...@@ -517,8 +513,7 @@ RecordABigRequest(pContext, client, stuff) ...@@ -517,8 +513,7 @@ RecordABigRequest(pContext, client, stuff)
* request for this client. The real Proc function is called. * request for this client. The real Proc function is called.
*/ */
static int static int
RecordARequest(client) RecordARequest(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
RecordClientsAndProtocolPtr pRCAP; RecordClientsAndProtocolPtr pRCAP;
...@@ -601,10 +596,7 @@ RecordARequest(client) ...@@ -601,10 +596,7 @@ RecordARequest(client)
* the word skip in ddx.tbl.ms (the porting layer document). * the word skip in ddx.tbl.ms (the porting layer document).
*/ */
static void static void
RecordASkippedRequest(pcbl , nulldata, calldata) RecordASkippedRequest(CallbackListPtr *pcbl, void * nulldata, void * calldata)
CallbackListPtr *pcbl;
void * nulldata;
void * calldata;
{ {
SkippedRequestInfoRec *psi = (SkippedRequestInfoRec *)calldata; SkippedRequestInfoRec *psi = (SkippedRequestInfoRec *)calldata;
RecordContextPtr pContext; RecordContextPtr pContext;
...@@ -691,10 +683,7 @@ RecordASkippedRequest(pcbl , nulldata, calldata) ...@@ -691,10 +683,7 @@ RecordASkippedRequest(pcbl , nulldata, calldata)
* chunk of data belonging to this reply, it is set to 0. * chunk of data belonging to this reply, it is set to 0.
*/ */
static void static void
RecordAReply(pcbl, nulldata, calldata) RecordAReply(CallbackListPtr *pcbl, void * nulldata, void * calldata)
CallbackListPtr *pcbl;
void * nulldata;
void * calldata;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
RecordClientsAndProtocolPtr pRCAP; RecordClientsAndProtocolPtr pRCAP;
...@@ -776,10 +765,7 @@ RecordAReply(pcbl, nulldata, calldata) ...@@ -776,10 +765,7 @@ RecordAReply(pcbl, nulldata, calldata)
* it for this client. * it for this client.
*/ */
static void static void
RecordADeliveredEventOrError(pcbl, nulldata, calldata) RecordADeliveredEventOrError(CallbackListPtr *pcbl, void * nulldata, void * calldata)
CallbackListPtr *pcbl;
void * nulldata;
void * calldata;
{ {
EventInfoRec *pei = (EventInfoRec *)calldata; EventInfoRec *pei = (EventInfoRec *)calldata;
RecordContextPtr pContext; RecordContextPtr pContext;
...@@ -845,10 +831,7 @@ RecordADeliveredEventOrError(pcbl, nulldata, calldata) ...@@ -845,10 +831,7 @@ RecordADeliveredEventOrError(pcbl, nulldata, calldata)
* it for this client. * it for this client.
*/ */
static void static void
RecordADeviceEvent(pcbl, nulldata, calldata) RecordADeviceEvent(CallbackListPtr *pcbl, void * nulldata, void * calldata)
CallbackListPtr *pcbl;
void * nulldata;
void * calldata;
{ {
DeviceEventInfoRec *pei = (DeviceEventInfoRec *)calldata; DeviceEventInfoRec *pei = (DeviceEventInfoRec *)calldata;
RecordContextPtr pContext; RecordContextPtr pContext;
...@@ -969,9 +952,7 @@ RecordFlushAllContexts( ...@@ -969,9 +952,7 @@ RecordFlushAllContexts(
* various callback lists. * various callback lists.
*/ */
static int static int
RecordInstallHooks(pRCAP, oneclient) RecordInstallHooks(RecordClientsAndProtocolPtr pRCAP, XID oneclient)
RecordClientsAndProtocolPtr pRCAP;
XID oneclient;
{ {
int i = 0; int i = 0;
XID client; XID client;
...@@ -1064,9 +1045,7 @@ RecordInstallHooks(pRCAP, oneclient) ...@@ -1064,9 +1045,7 @@ RecordInstallHooks(pRCAP, oneclient)
* various callback lists. * various callback lists.
*/ */
static void static void
RecordUninstallHooks(pRCAP, oneclient) RecordUninstallHooks(RecordClientsAndProtocolPtr pRCAP, XID oneclient)
RecordClientsAndProtocolPtr pRCAP;
XID oneclient;
{ {
int i = 0; int i = 0;
XID client; XID client;
...@@ -1165,9 +1144,7 @@ RecordUninstallHooks(pRCAP, oneclient) ...@@ -1165,9 +1144,7 @@ RecordUninstallHooks(pRCAP, oneclient)
* have at least one client.) * have at least one client.)
*/ */
static void static void
RecordDeleteClientFromRCAP(pRCAP, position) RecordDeleteClientFromRCAP(RecordClientsAndProtocolPtr pRCAP, int position)
RecordClientsAndProtocolPtr pRCAP;
int position;
{ {
if (pRCAP->pContext->pRecordingClient) if (pRCAP->pContext->pRecordingClient)
RecordUninstallHooks(pRCAP, pRCAP->pClientIDs[position]); RecordUninstallHooks(pRCAP, pRCAP->pClientIDs[position]);
...@@ -1214,9 +1191,7 @@ RecordDeleteClientFromRCAP(pRCAP, position) ...@@ -1214,9 +1191,7 @@ RecordDeleteClientFromRCAP(pRCAP, position)
* is no more room to hold clients internal to the RCAP. * is no more room to hold clients internal to the RCAP.
*/ */
static void static void
RecordAddClientToRCAP(pRCAP, clientspec) RecordAddClientToRCAP(RecordClientsAndProtocolPtr pRCAP, XID clientspec)
RecordClientsAndProtocolPtr pRCAP;
XID clientspec;
{ {
if (pRCAP->numClients == pRCAP->sizeClients) if (pRCAP->numClients == pRCAP->sizeClients)
{ {
...@@ -1262,9 +1237,7 @@ RecordAddClientToRCAP(pRCAP, clientspec) ...@@ -1262,9 +1237,7 @@ RecordAddClientToRCAP(pRCAP, clientspec)
* RCAP. (A given clientspec can only be on one RCAP of a context.) * RCAP. (A given clientspec can only be on one RCAP of a context.)
*/ */
static void static void
RecordDeleteClientFromContext(pContext, clientspec) RecordDeleteClientFromContext(RecordContextPtr pContext, XID clientspec)
RecordContextPtr pContext;
XID clientspec;
{ {
RecordClientsAndProtocolPtr pRCAP; RecordClientsAndProtocolPtr pRCAP;
int position; int position;
...@@ -1287,10 +1260,7 @@ RecordDeleteClientFromContext(pContext, clientspec) ...@@ -1287,10 +1260,7 @@ RecordDeleteClientFromContext(pContext, clientspec)
* Side Effects: none. * Side Effects: none.
*/ */
static int static int
RecordSanityCheckClientSpecifiers(clientspecs, nspecs, errorspec) RecordSanityCheckClientSpecifiers(XID *clientspecs, int nspecs, XID errorspec)
XID *clientspecs;
int nspecs;
XID errorspec;
{ {
int i; int i;
int clientIndex; int clientIndex;
...@@ -1349,10 +1319,7 @@ RecordSanityCheckClientSpecifiers(clientspecs, nspecs, errorspec) ...@@ -1349,10 +1319,7 @@ RecordSanityCheckClientSpecifiers(clientspecs, nspecs, errorspec)
* pClientspecs may be modified in place. * pClientspecs may be modified in place.
*/ */
static XID * static XID *
RecordCanonicalizeClientSpecifiers(pClientspecs, pNumClientspecs, excludespec) RecordCanonicalizeClientSpecifiers(XID *pClientspecs, int *pNumClientspecs, XID excludespec)
XID *pClientspecs;
int *pNumClientspecs;
XID excludespec;
{ {
int i; int i;
int numClients = *pNumClientspecs; int numClients = *pNumClientspecs;
...@@ -1449,10 +1416,7 @@ RecordPadAlign(int size, int align) ...@@ -1449,10 +1416,7 @@ RecordPadAlign(int size, int align)
* Side Effects: none. * Side Effects: none.
*/ */
static int static int
RecordSanityCheckRegisterClients(pContext, client, stuff) RecordSanityCheckRegisterClients(RecordContextPtr pContext, ClientPtr client, xRecordRegisterClientsReq *stuff)
RecordContextPtr pContext;
ClientPtr client;
xRecordRegisterClientsReq *stuff;
{ {
int err; int err;
xRecordRange *pRange; xRecordRange *pRange;
...@@ -1587,9 +1551,7 @@ enum {REQ, /* set info for requests */ ...@@ -1587,9 +1551,7 @@ enum {REQ, /* set info for requests */
* RecordSetIntervals, all zeroed, and psi->size is set to size. * RecordSetIntervals, all zeroed, and psi->size is set to size.
*/ */
static int static int
RecordAllocIntervals(psi, nIntervals) RecordAllocIntervals(SetInfoPtr psi, int nIntervals)
SetInfoPtr psi;
int nIntervals;
{ {
assert(!psi->intervals); assert(!psi->intervals);
psi->intervals = (RecordSetInterval *) psi->intervals = (RecordSetInterval *)
...@@ -1711,10 +1673,7 @@ RecordConvertRangesToIntervals( ...@@ -1711,10 +1673,7 @@ RecordConvertRangesToIntervals(
* to record the new clients and protocol. * to record the new clients and protocol.
*/ */
static int static int
RecordRegisterClients(pContext, client, stuff) RecordRegisterClients(RecordContextPtr pContext, ClientPtr client, xRecordRegisterClientsReq *stuff)
RecordContextPtr pContext;
ClientPtr client;
xRecordRegisterClientsReq *stuff;
{ {
int err; int err;
int i; int i;
...@@ -1987,8 +1946,7 @@ bailout: ...@@ -1987,8 +1946,7 @@ bailout:
*/ */
static int static int
ProcRecordQueryVersion(client) ProcRecordQueryVersion(ClientPtr client)
ClientPtr client;
{ {
/* REQUEST(xRecordQueryVersionReq); */ /* REQUEST(xRecordQueryVersionReq); */
xRecordQueryVersionReply rep; xRecordQueryVersionReply rep;
...@@ -2012,8 +1970,7 @@ ProcRecordQueryVersion(client) ...@@ -2012,8 +1970,7 @@ ProcRecordQueryVersion(client)
static int static int
ProcRecordCreateContext(client) ProcRecordCreateContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordCreateContextReq); REQUEST(xRecordCreateContextReq);
RecordContextPtr pContext; RecordContextPtr pContext;
...@@ -2068,8 +2025,7 @@ bailout: ...@@ -2068,8 +2025,7 @@ bailout:
static int static int
ProcRecordRegisterClients(client) ProcRecordRegisterClients(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
REQUEST(xRecordRegisterClientsReq); REQUEST(xRecordRegisterClientsReq);
...@@ -2082,8 +2038,7 @@ ProcRecordRegisterClients(client) ...@@ -2082,8 +2038,7 @@ ProcRecordRegisterClients(client)
static int static int
ProcRecordUnregisterClients(client) ProcRecordUnregisterClients(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
int err; int err;
...@@ -2147,9 +2102,7 @@ typedef struct { ...@@ -2147,9 +2102,7 @@ typedef struct {
* number of ranges. Newly allocated ranges are zeroed. * number of ranges. Newly allocated ranges are zeroed.
*/ */
static int static int
RecordAllocRanges(pri, nRanges) RecordAllocRanges(GetContextRangeInfoPtr pri, int nRanges)
GetContextRangeInfoPtr pri;
int nRanges;
{ {
int newsize; int newsize;
xRecordRange *pNewRange; xRecordRange *pNewRange;
...@@ -2309,9 +2262,7 @@ RecordConvertMinorOpInfoToRanges( ...@@ -2309,9 +2262,7 @@ RecordConvertMinorOpInfoToRanges(
* The 16 bit fields of each xRecordRange are byte swapped. * The 16 bit fields of each xRecordRange are byte swapped.
*/ */
static void static void
RecordSwapRanges(pRanges, nRanges) RecordSwapRanges(xRecordRange *pRanges, int nRanges)
xRecordRange *pRanges;
int nRanges;
{ {
int i; int i;
for (i = 0; i < nRanges; i++, pRanges++) for (i = 0; i < nRanges; i++, pRanges++)
...@@ -2325,8 +2276,7 @@ RecordSwapRanges(pRanges, nRanges) ...@@ -2325,8 +2276,7 @@ RecordSwapRanges(pRanges, nRanges)
static int static int
ProcRecordGetContext(client) ProcRecordGetContext(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
REQUEST(xRecordGetContextReq); REQUEST(xRecordGetContextReq);
...@@ -2471,8 +2421,7 @@ bailout: ...@@ -2471,8 +2421,7 @@ bailout:
static int static int
ProcRecordEnableContext(client) ProcRecordEnableContext(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
REQUEST(xRecordEnableContextReq); REQUEST(xRecordEnableContextReq);
...@@ -2550,8 +2499,7 @@ ProcRecordEnableContext(client) ...@@ -2550,8 +2499,7 @@ ProcRecordEnableContext(client)
* is resumed. * is resumed.
*/ */
static void static void
RecordDisableContext(pContext) RecordDisableContext(RecordContextPtr pContext)
RecordContextPtr pContext;
{ {
RecordClientsAndProtocolPtr pRCAP; RecordClientsAndProtocolPtr pRCAP;
int i; int i;
...@@ -2588,8 +2536,7 @@ RecordDisableContext(pContext) ...@@ -2588,8 +2536,7 @@ RecordDisableContext(pContext)
static int static int
ProcRecordDisableContext(client) ProcRecordDisableContext(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
REQUEST(xRecordDisableContextReq); REQUEST(xRecordDisableContextReq);
...@@ -2614,9 +2561,7 @@ ProcRecordDisableContext(client) ...@@ -2614,9 +2561,7 @@ ProcRecordDisableContext(client)
* it from the ppAllContexts array. * it from the ppAllContexts array.
*/ */
static int static int
RecordDeleteContext(value, id) RecordDeleteContext(void * value, XID id)
void * value;
XID id;
{ {
int i; int i;
RecordContextPtr pContext = (RecordContextPtr)value; RecordContextPtr pContext = (RecordContextPtr)value;
...@@ -2656,8 +2601,7 @@ RecordDeleteContext(value, id) ...@@ -2656,8 +2601,7 @@ RecordDeleteContext(value, id)
static int static int
ProcRecordFreeContext(client) ProcRecordFreeContext(ClientPtr client)
ClientPtr client;
{ {
RecordContextPtr pContext; RecordContextPtr pContext;
REQUEST(xRecordFreeContextReq); REQUEST(xRecordFreeContextReq);
...@@ -2670,8 +2614,7 @@ ProcRecordFreeContext(client) ...@@ -2670,8 +2614,7 @@ ProcRecordFreeContext(client)
static int static int
ProcRecordDispatch(client) ProcRecordDispatch(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xReq); REQUEST(xReq);
...@@ -2700,8 +2643,7 @@ ProcRecordDispatch(client) ...@@ -2700,8 +2643,7 @@ ProcRecordDispatch(client)
static int static int
SProcRecordQueryVersion(client) SProcRecordQueryVersion(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordQueryVersionReq); REQUEST(xRecordQueryVersionReq);
...@@ -2738,8 +2680,7 @@ SwapCreateRegister(xRecordRegisterClientsReq *stuff) ...@@ -2738,8 +2680,7 @@ SwapCreateRegister(xRecordRegisterClientsReq *stuff)
static int static int
SProcRecordCreateContext(client) SProcRecordCreateContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordCreateContextReq); REQUEST(xRecordCreateContextReq);
int status; int status;
...@@ -2753,8 +2694,7 @@ SProcRecordCreateContext(client) ...@@ -2753,8 +2694,7 @@ SProcRecordCreateContext(client)
static int static int
SProcRecordRegisterClients(client) SProcRecordRegisterClients(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordRegisterClientsReq); REQUEST(xRecordRegisterClientsReq);
int status; int status;
...@@ -2768,8 +2708,7 @@ SProcRecordRegisterClients(client) ...@@ -2768,8 +2708,7 @@ SProcRecordRegisterClients(client)
static int static int
SProcRecordUnregisterClients(client) SProcRecordUnregisterClients(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordUnregisterClientsReq); REQUEST(xRecordUnregisterClientsReq);
...@@ -2783,8 +2722,7 @@ SProcRecordUnregisterClients(client) ...@@ -2783,8 +2722,7 @@ SProcRecordUnregisterClients(client)
static int static int
SProcRecordGetContext(client) SProcRecordGetContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordGetContextReq); REQUEST(xRecordGetContextReq);
...@@ -2795,8 +2733,7 @@ SProcRecordGetContext(client) ...@@ -2795,8 +2733,7 @@ SProcRecordGetContext(client)
} /* SProcRecordGetContext */ } /* SProcRecordGetContext */
static int static int
SProcRecordEnableContext(client) SProcRecordEnableContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordEnableContextReq); REQUEST(xRecordEnableContextReq);
...@@ -2808,8 +2745,7 @@ SProcRecordEnableContext(client) ...@@ -2808,8 +2745,7 @@ SProcRecordEnableContext(client)
static int static int
SProcRecordDisableContext(client) SProcRecordDisableContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordDisableContextReq); REQUEST(xRecordDisableContextReq);
...@@ -2821,8 +2757,7 @@ SProcRecordDisableContext(client) ...@@ -2821,8 +2757,7 @@ SProcRecordDisableContext(client)
static int static int
SProcRecordFreeContext(client) SProcRecordFreeContext(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xRecordFreeContextReq); REQUEST(xRecordFreeContextReq);
...@@ -2834,8 +2769,7 @@ SProcRecordFreeContext(client) ...@@ -2834,8 +2769,7 @@ SProcRecordFreeContext(client)
static int static int
SProcRecordDispatch(client) SProcRecordDispatch(ClientPtr client)
ClientPtr client;
{ {
REQUEST(xReq); REQUEST(xReq);
...@@ -2875,16 +2809,14 @@ SProcRecordDispatch(client) ...@@ -2875,16 +2809,14 @@ SProcRecordDispatch(client)
* The connection setup info is sent to the recording client. * The connection setup info is sent to the recording client.
*/ */
static void static void
RecordConnectionSetupInfo(pContext, pci) RecordConnectionSetupInfo(RecordContextPtr pContext, NewClientInfoRec *pci)
RecordContextPtr pContext;
NewClientInfoRec *pci;
{ {
int prefixsize = SIZEOF(xConnSetupPrefix); int prefixsize = SIZEOF(xConnSetupPrefix);
int restsize = pci->prefix->length * 4; int restsize = pci->prefix->length * 4;
if (pci->client->swapped) if (pci->client->swapped)
{ {
char * pConnSetup = (char *)malloc(prefixsize + restsize); char *pConnSetup = (char *)malloc(prefixsize + restsize);
if (!pConnSetup) if (!pConnSetup)
return; return;
SwapConnSetupPrefix(pci->prefix, (xConnSetupPrefix*)pConnSetup); SwapConnSetupPrefix(pci->prefix, (xConnSetupPrefix*)pConnSetup);
...@@ -2930,10 +2862,7 @@ RecordConnectionSetupInfo(pContext, pci) ...@@ -2930,10 +2862,7 @@ RecordConnectionSetupInfo(pContext, pci)
*/ */
static void static void
RecordAClientStateChange(pcbl, nulldata, calldata) RecordAClientStateChange(CallbackListPtr *pcbl, void * nulldata, void * calldata)
CallbackListPtr *pcbl;
void * nulldata;
void * calldata;
{ {
NewClientInfoRec *pci = (NewClientInfoRec *)calldata; NewClientInfoRec *pci = (NewClientInfoRec *)calldata;
int i; int i;
...@@ -2996,8 +2925,7 @@ RecordAClientStateChange(pcbl, nulldata, calldata) ...@@ -2996,8 +2925,7 @@ RecordAClientStateChange(pcbl, nulldata, calldata)
* *
*/ */
static void static void
RecordCloseDown(extEntry) RecordCloseDown(ExtensionEntry *extEntry)
ExtensionEntry *extEntry;
{ {
DeleteCallback(&ClientStateCallback, RecordAClientStateChange, NULL); DeleteCallback(&ClientStateCallback, RecordAClientStateChange, NULL);
} /* RecordCloseDown */ } /* RecordCloseDown */
......
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