commit 892d26a22f85204e558a0ba8e52307bd644118f3
parent bfc45a1b9d25b6e39a18c151e9fe3a22a439c735
Author: Sebastian <sebastian@sebsite.pw>
Date: Sat, 9 Apr 2022 15:44:24 -0400
net::unix: s/null-terminated/NUL-terminated/g
The documentation in the stdlib should be consistent. "NUL" is also
preferable here because it lessens confusion with Hare's concept of
"null".
Signed-off-by: Sebastian <sebastian@sebsite.pw>
Diffstat:
2 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/net/unix/+freebsd.ha b/net/unix/+freebsd.ha
@@ -86,7 +86,7 @@ export fn listen(
// Converts a UNIX socket address to a native sockaddr.
fn to_native(addr: addr) (rt::sockaddr | invalid) = {
- // sun_path should be null-terminated and fit into rt::UNIX_PATH_MAX
+ // sun_path should be NUL-terminated and fit into rt::UNIX_PATH_MAX
if (len(addr) > rt::UNIX_PATH_MAX - 1) {
return invalid;
};
diff --git a/net/unix/+linux.ha b/net/unix/+linux.ha
@@ -87,7 +87,7 @@ export fn listen(
// Converts a UNIX socket address to a native sockaddr.
fn to_native(addr: addr) (rt::sockaddr | invalid) = {
- // sun_path should be null-terminated and fit into rt::UNIX_PATH_MAX
+ // sun_path should be NUL-terminated and fit into rt::UNIX_PATH_MAX
if (len(addr) > rt::UNIX_PATH_MAX - 1) {
return invalid;
};