Skip to content

Conversation

@metux
Copy link
Contributor

@metux metux commented Nov 4, 2025

  • the GrabInProgress field isn't used by any known drivers, thus
    no need to export it
  • the only in-tree consumer outside of it's source file is Xext/saver.c,
    which actually just wants to know whether any other client already
    grabbed the server - asking the OS layer isn't the right source
    (should ask dix/dispatch.c instead)

Therefore adding a simple function for that check into dispatch.c (where
grab/ungrab is actually controlled), so we can easily make this internal
field static again.

Signed-off-by: Enrico Weigelt, metux IT consult info@metux.net

* the `GrabInProgress` field isn't used by any known drivers, thus
  no need to export it
* the only in-tree consumer outside of it's source file is Xext/saver.c,
  which actually just wants to know whether any *other* client already
  grabbed the server - asking the OS layer isn't the right source
  (should ask dix/dispatch.c instead)

Therefore adding a simple function for that check into dispatch.c (where
grab/ungrab is actually controlled), so we can easily make this internal
field static again.

Signed-off-by: Enrico Weigelt, metux IT consult <info@metux.net>
pPriv->installedMap = None;

if (GrabInProgress && GrabInProgress != pAttr->client->index)
if (dixAnyOtherGrabbed(pAttr->client))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not familiar with this code, but did you intend to move to check to grabClient instead of GrabInProgress?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unless i haven't overlooked anything, these two variables updated at almost the same time.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants