trilemma-dev / SecureXPC

A simple and secure XPC framework for Swift
MIT License
75 stars 15 forks source link

Creating an `XPCAnonymousServer` or `XPCMachServer` and never starting it results in XPC API Misuse #54

Closed jakaplan closed 2 years ago

jakaplan commented 2 years ago

If either of these types of servers are created, but never started, then when they are deallocated the following is thrown:

XPC API Misuse: Release of last reference on a suspended connection.

After a bunch of debugging and documentation reading I'm pretty sure what's going on is the following:

Reproducing this issue with a test is trivial, just create a new test and the entire function's body should just be:

XPCServer.makeAnonymous()