When a port is unavailable, veb segfaults #22292
Labels
Bug
This tag is applied to issues which reports bugs.
Status: Confirmed
This bug has been confirmed to be valid by a contributor.
Unit: veb
Bugs/feature requests, that are related to the `veb`, V's official web framework.
V doctor:
What did you do?
Run the same veb instance twice on the same machine.
The first run works fine, and the port 8080 will be serving.
The second run fails to acquire the port 8080. Instead of failing gracefully, it throws a segfaiult
./v -g -o vdbg cmd/v && ./vdbg /tmp/x.v
What did you expect to see?
When a port is unavailable, veb should fail gracefully
What did you see instead?
[veb] Running app on http://localhost:8080/ Error during listen: net: socket error: 48; binding to :8080 failed signal 11: segmentation fault 0 libsystem_platform.dylib 0x000000018ba72584 _sigtramp + 56 1 x 0x000000010493b64c picoev__Picoev_loop_once + 24 2 x 0x000000010493d5f8 picoev__Picoev_serve + 204 3 x 0x000000010495cfe8 veb__run_at_T_main__App_main__Context + 1924 4 x 0x000000010495c808 veb__run_T_main__App_main__Context + 116 5 x 0x0000000104961ee8 main__main + 68 6 x 0x0000000104963a6c main + 88 7 dyld 0x000000018b6b7154 start + 2476
Note
You can use the 👍 reaction to increase the issue's priority for developers.
Please note that only the 👍 reaction to the issue itself counts as a vote.
Other reactions and those to comments will not be taken into account.
The text was updated successfully, but these errors were encountered: