xace: add hooks + new access codes: SHAPE extension
This commit is contained in:
parent
766c693ef3
commit
53f346b158
26
Xext/shape.c
26
Xext/shape.c
|
@ -323,7 +323,7 @@ ProcShapeRectangles (client)
|
||||||
|
|
||||||
REQUEST_AT_LEAST_SIZE (xShapeRectanglesReq);
|
REQUEST_AT_LEAST_SIZE (xShapeRectanglesReq);
|
||||||
UpdateCurrentTime();
|
UpdateCurrentTime();
|
||||||
rc = dixLookupWindow(&pWin, stuff->dest, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pWin, stuff->dest, client, DixSetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
switch (stuff->destKind) {
|
switch (stuff->destKind) {
|
||||||
|
@ -423,7 +423,7 @@ ProcShapeMask (client)
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeMaskReq);
|
REQUEST_SIZE_MATCH (xShapeMaskReq);
|
||||||
UpdateCurrentTime();
|
UpdateCurrentTime();
|
||||||
rc = dixLookupWindow(&pWin, stuff->dest, client, DixWriteAccess);
|
rc = dixLookupWindow(&pWin, stuff->dest, client, DixSetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
switch (stuff->destKind) {
|
switch (stuff->destKind) {
|
||||||
|
@ -444,10 +444,10 @@ ProcShapeMask (client)
|
||||||
if (stuff->src == None)
|
if (stuff->src == None)
|
||||||
srcRgn = 0;
|
srcRgn = 0;
|
||||||
else {
|
else {
|
||||||
pPixmap = (PixmapPtr) SecurityLookupIDByType(client, stuff->src,
|
rc = dixLookupResource((pointer *)&pPixmap, stuff->src, RT_PIXMAP,
|
||||||
RT_PIXMAP, DixReadAccess);
|
client, DixReadAccess);
|
||||||
if (!pPixmap)
|
if (rc != Success)
|
||||||
return BadPixmap;
|
return (rc == BadValue) ? BadPixmap : rc;
|
||||||
if (pPixmap->drawable.pScreen != pScreen ||
|
if (pPixmap->drawable.pScreen != pScreen ||
|
||||||
pPixmap->drawable.depth != 1)
|
pPixmap->drawable.depth != 1)
|
||||||
return BadMatch;
|
return BadMatch;
|
||||||
|
@ -531,7 +531,7 @@ ProcShapeCombine (client)
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeCombineReq);
|
REQUEST_SIZE_MATCH (xShapeCombineReq);
|
||||||
UpdateCurrentTime();
|
UpdateCurrentTime();
|
||||||
rc = dixLookupWindow(&pDestWin, stuff->dest, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pDestWin, stuff->dest, client, DixSetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
if (!pDestWin->optional)
|
if (!pDestWin->optional)
|
||||||
|
@ -552,7 +552,7 @@ ProcShapeCombine (client)
|
||||||
}
|
}
|
||||||
pScreen = pDestWin->drawable.pScreen;
|
pScreen = pDestWin->drawable.pScreen;
|
||||||
|
|
||||||
rc = dixLookupWindow(&pSrcWin, stuff->src, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pSrcWin, stuff->src, client, DixGetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
switch (stuff->srcKind) {
|
switch (stuff->srcKind) {
|
||||||
|
@ -651,7 +651,7 @@ ProcShapeOffset (client)
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeOffsetReq);
|
REQUEST_SIZE_MATCH (xShapeOffsetReq);
|
||||||
UpdateCurrentTime();
|
UpdateCurrentTime();
|
||||||
rc = dixLookupWindow(&pWin, stuff->dest, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pWin, stuff->dest, client, DixSetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
switch (stuff->destKind) {
|
switch (stuff->destKind) {
|
||||||
|
@ -716,7 +716,7 @@ ProcShapeQueryExtents (client)
|
||||||
RegionPtr region;
|
RegionPtr region;
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeQueryExtentsReq);
|
REQUEST_SIZE_MATCH (xShapeQueryExtentsReq);
|
||||||
rc = dixLookupWindow(&pWin, stuff->window, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
rep.type = X_Reply;
|
rep.type = X_Reply;
|
||||||
|
@ -826,7 +826,7 @@ ProcShapeSelectInput (client)
|
||||||
int rc;
|
int rc;
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeSelectInputReq);
|
REQUEST_SIZE_MATCH (xShapeSelectInputReq);
|
||||||
rc = dixLookupWindow(&pWin, stuff->window, client, DixWriteAccess);
|
rc = dixLookupWindow(&pWin, stuff->window, client, DixReceiveAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
pHead = (ShapeEventPtr *)SecurityLookupIDByType(client,
|
pHead = (ShapeEventPtr *)SecurityLookupIDByType(client,
|
||||||
|
@ -999,7 +999,7 @@ ProcShapeInputSelected (client)
|
||||||
register int n;
|
register int n;
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH (xShapeInputSelectedReq);
|
REQUEST_SIZE_MATCH (xShapeInputSelectedReq);
|
||||||
rc = dixLookupWindow(&pWin, stuff->window, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
pHead = (ShapeEventPtr *) SecurityLookupIDByType(client,
|
pHead = (ShapeEventPtr *) SecurityLookupIDByType(client,
|
||||||
|
@ -1041,7 +1041,7 @@ ProcShapeGetRectangles (client)
|
||||||
register int n;
|
register int n;
|
||||||
|
|
||||||
REQUEST_SIZE_MATCH(xShapeGetRectanglesReq);
|
REQUEST_SIZE_MATCH(xShapeGetRectanglesReq);
|
||||||
rc = dixLookupWindow(&pWin, stuff->window, client, DixUnknownAccess);
|
rc = dixLookupWindow(&pWin, stuff->window, client, DixGetAttrAccess);
|
||||||
if (rc != Success)
|
if (rc != Success)
|
||||||
return rc;
|
return rc;
|
||||||
switch (stuff->kind) {
|
switch (stuff->kind) {
|
||||||
|
|
Loading…
Reference in New Issue