Laytan Laats
5c63617191
net: fix leaking sockets in listen_tcp if an error occurs
2024-10-08 21:08:14 +02:00
Laytan Laats
d8af35f01e
net: fix leaking sockets in dial_tcp if connect errors
2024-10-08 21:01:57 +02:00
gingerBill
327ca2ab71
Merge pull request #4261 from laytan/net-bound-endpoint
...
net: add `bound_endpoint` procedure
2024-09-19 12:53:42 +01:00
Laytan Laats
652557bfcd
net: add bound_endpoint procedure
2024-09-17 22:22:19 +02:00
Karl Zylinski
3d7b924260
Fix a few incorrectly placed build tags.
2024-09-14 18:41:05 +02:00
Karl Zylinski
19f0127e55
Moved all packages in core, base, vendor, tests and examples to use new #+ file tag syntax.
2024-09-14 18:27:49 +02:00
Laytan Laats
288312a812
core: improve package doc comments for the documentation generator
2024-09-03 19:59:04 +02:00
Jeroen van Rijn
0a825fc44d
Improve SRV handling in dns_windows.odin
2024-08-24 18:43:25 +02:00
gingerBill
70932dc478
Merge pull request #4089 from laytan/riscv64
...
add support for linux_riscv64 and freestanding_riscv64
2024-08-22 11:20:03 +01:00
Laytan
06fb500dfe
make sure net.Network_Error is of size 8
2024-08-20 15:52:07 +02:00
Laytan
ca6ef95b03
add support for linux_riscv64 and freestanding_riscv64
2024-08-20 14:06:40 +02:00
Jeroen van Rijn
cc24d2de3e
Merge pull request #3810 from Feoramund/freebsd-core-net
...
Port `core:net` to FreeBSD
2024-08-09 09:50:05 +02:00
Feoramund
4c0ab09c9a
Handle EPIPE in Darwin core:net
2024-08-05 13:15:08 -04:00
Feoramund
6cc7f3b451
Add FreeBSD Accept_Error.Would_Block alias
2024-08-05 13:00:44 -04:00
Feoramund
3512d7c672
Move Darwin MSG_NOSIGNAL to core:os
2024-08-05 12:49:12 -04:00
Feoramund
eba0774bf3
Prevent SIGPIPE on Darwin when writing to a closed core:net socket
...
Mimics behavior found on Linux implementation.
2024-08-05 12:23:09 -04:00
Feoramund
fe754af13d
Add new contribution notes to core:net
2024-08-05 03:05:49 -04:00
Feoramund
61e770d943
Clean up some FreeBSD core:net code
2024-08-05 03:05:43 -04:00
Feoramund
2b63684ccf
Fix integer socket option values for FreeBSD
2024-08-05 02:14:41 -04:00
Feoramund
5ece6980eb
Make EINVAL generic in FreeBSD Socket_Option_Error
...
The documentation for `setsockopt(2)` mentioned accept filters for
`EINVAL`, but I've found that it can arise for any manner of invalid
values for setting socket options.
We'll just have to leave this as a generic error.
2024-08-05 02:14:27 -04:00
Feoramund
8de48d81ea
Use common name for ENOBUFS
2024-08-05 00:30:39 -04:00
Feoramund
32fb1fb61c
Add missing ECONNRESET TCP_Send_Error
...
This was not specifically documented in `send(2)`.
2024-08-05 00:30:39 -04:00
Feoramund
05c50561ae
Set NOSIGPIPE on all core:net FreeBSD sockets
2024-08-05 00:30:39 -04:00
Feoramund
46455dd0a6
Add more socket options for FreeBSD core:net
2024-08-05 00:30:24 -04:00
gingerBill
66b86bc7e0
Correct os errors for darwin
2024-08-04 12:23:18 +01:00
gingerBill
97c499dbb4
Begin mapping os.Error in the rest of the codebase
2024-08-04 11:58:04 +01:00
flysand7
4dcb75af6d
Make all handles non-inheritable by default
...
The sockets are left as non-inheritable because they
never should be inherited.
2024-07-18 22:50:47 +11:00
Feoramund
8b915aae5e
Update code for new -vet
2024-06-30 11:18:40 -04:00
h0mtanks
2b615b09f0
fixed whitespace
2024-06-30 13:47:11 +05:30
h0mtanks
d1603ebac4
added missing would_block enum member
2024-06-30 13:42:55 +05:30
gingerBill
e296d6fb90
Fix loads of indentation issues with mixing spaces and tabs
2024-06-29 19:50:51 +01:00
gingerBill
103eccf104
More style improvements
2024-06-29 19:23:58 +01:00
gingerBill
5413a8b744
Even more style fixes
2024-06-29 19:11:36 +01:00
gingerBill
c88a1bef91
Add another -vet-cast check
2024-06-29 12:40:04 +01:00
Feoramund
e61d893a74
Port core:net to FreeBSD
2024-06-26 10:05:24 -04:00
gingerBill
f9fd8f0c25
Merge pull request #3439 from andreas-jonsson/netbsd
...
NetBSD support
2024-05-15 10:33:52 +01:00
gingerBill
6dc0ee3877
Fix #3577
2024-05-13 12:54:01 +01:00
Andreas T Jonsson
9a008d10f3
Merge branch 'master' into netbsd
2024-04-25 22:04:40 +02:00
Rickard Andersson
68f663ea85
fix(net): fix return type for send_tcp
...
Was `.Connection_Closed` but this is only inferrable if our return type
is not a sub-union of another.
2024-04-19 15:39:04 +03:00
Rickard Andersson
efc84cd390
docs(net): add comment about EPIPE -> Connection_Closed
2024-04-19 15:37:20 +03:00
Rickard Andersson
7b95562827
feat(net): turn EPIPE into Connection_Closed
2024-04-19 15:29:28 +03:00
Rickard Andersson
c44f618b7d
fix(net): add NOSIGNAL to send options
...
This is a better default than not having it, since it turns errors that
would be signals into error values instead. We could take these as
options but given that we currently don't I think this at the very least
improves on the status quo.
2024-04-19 15:17:21 +03:00
Andreas T Jonsson
dd95a8d11d
More std lib fixes
...
Just selecting the same codepath as other BSD's for the most part.
2024-04-19 10:42:09 +02:00
blob1807
2d1260bec9
uniformity change
...
small change to check things uniform
2024-04-13 00:47:49 +10:00
blob1807
c753711d86
Added support for URL fragments
...
Added support for a URL's fragment/anchor to `split_url` & `join_url` in `core:net` plus 4 new tests to cover it.
2024-04-13 00:39:32 +10:00
Laytan Laats
3a0df80066
correct newly found vets
2024-04-03 00:52:58 +02:00
Tetralux
d74ddb2d91
fixup
2024-02-22 15:01:55 +00:00
Tetralux
ec0831da70
[net] Better error code for binding a privileged port without root access on Darwin
...
This condition results in os.EACCESS, which we were translating to Broadcast_Disabled.
This was the case because binding to the broadcast address on a UDP port, without setting the BROADCAST flag, also results in this error.
Given the fact that reserved ports also produce this error, we now check for this condition in net.bind() and translate it to a custom, clearer error:
Privileged_Port_Without_Root.
2024-02-22 14:55:27 +00:00
gingerBill
3e7e779abf
Replace core:* to base:* where appropriate
2024-01-28 22:18:51 +00:00
flysand7
ff0e976ff3
[net]: Fix passing the wrong socket to on linux
2023-11-24 23:57:53 +11:00