app_server & Interface Kit: Rework cursor reference management.

We can't allow applications to reference/unreference cursors,
this is a safety/security violation, and it being done improperly
lead to the reference counts becoming incorrect on the app_server
side.

Change AS_REFERENCE_CURSOR to AS_CLONE_CURSOR and adjust the Cursor
code appropriately. (In the future, copying BCursor without Clone'ing
the data in the case of custom cursors could be accomplished with
client-side reference counting.)

Then rework CursorManager to remove cursors at once on team deletion,
and otherwise clean up cursor reference management to let the
reference counting handle things.
This commit is contained in:
Augustin Cavalier
2024-07-30 20:51:53 -04:00
parent 917dcdfe75
commit 4448758b3e
8 changed files with 55 additions and 52 deletions
+1 -1
View File
@@ -74,7 +74,7 @@ enum {
AS_CREATE_CURSOR,
AS_CREATE_CURSOR_BITMAP,
AS_REFERENCE_CURSOR,
AS_CLONE_CURSOR,
AS_DELETE_CURSOR,
AS_BEGIN_RECT_TRACKING,