Skip to content

[core] When address is already in use, local server blocks with swift task continuation misused #470

Closed
@sebsto

Description

@sebsto

Steps to reproduce:

  • Start the local server for one of the examples
  • From another terminal, start another local server.

Current behavior:
The second server blocks with message SWIFT TASK CONTINUATION MISUSE: withLocalServer(invocationEndpoint:_:) leaked its continuation!

Desired behavior:
Local server fails to start with an error like bind(descriptor:ptr:bytes:): Address already in use (errno: 48)

Root cause:
This block of code must be wrapped into a do catch block and call continuation.resume(throwing: error) when an error is throw.

Metadata

Metadata

Assignees

Labels

good first issueGood for newcomerskind/bugFeature doesn't work as expected.semver/noneNo version bump required.size/SSmall task. (A couple of hours of work.)

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions