summaryrefslogtreecommitdiff
path: root/lib9p/tests/test_server/fs_whoami.c
diff options
context:
space:
mode:
authorLuke T. Shumaker <lukeshu@lukeshu.com>2025-05-29 22:25:02 -0400
committerLuke T. Shumaker <lukeshu@lukeshu.com>2025-06-06 23:01:30 -0600
commit945756b1b050bdf09d1119854cc5b22ad15efacd (patch)
tree8223c149ea0ff2863ffd2e1a90c2ebdfe8eb8b4b /lib9p/tests/test_server/fs_whoami.c
parent8a9fc1704dcf3ec117a3bf37fd70a44a43873659 (diff)
lib9p_core: Switch to use error.h
Diffstat (limited to 'lib9p/tests/test_server/fs_whoami.c')
-rw-r--r--lib9p/tests/test_server/fs_whoami.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/lib9p/tests/test_server/fs_whoami.c b/lib9p/tests/test_server/fs_whoami.c
index 273d659..14dd0ba 100644
--- a/lib9p/tests/test_server/fs_whoami.c
+++ b/lib9p/tests/test_server/fs_whoami.c
@@ -73,12 +73,12 @@ static struct lib9p_srv_stat whoami_file_stat(struct whoami_file *self, struct l
static void whoami_file_wstat(struct whoami_file *self, struct lib9p_srv_ctx *ctx, struct lib9p_srv_stat) {
assert(self);
assert(ctx);
- lib9p_error(&ctx->basectx, E_POSIX_EROFS, "cannot wstat API file");
+ lib9p_error(ctx, E_POSIX_EROFS, "cannot wstat API file");
}
static void whoami_file_remove(struct whoami_file *self, struct lib9p_srv_ctx *ctx) {
assert(self);
assert(ctx);
- lib9p_error(&ctx->basectx, E_POSIX_EROFS, "cannot remove API file");
+ lib9p_error(ctx, E_POSIX_EROFS, "cannot remove API file");
}
LIB9P_SRV_NOTDIR(struct whoami_file, whoami_file)
@@ -137,8 +137,7 @@ static void whoami_fio_pread(struct whoami_fio *self, struct lib9p_srv_ctx *ctx,
ctx->user->num, ctx->user->name.len, ctx->user->name.utf8);
if (byte_offset > (uint64_t)data_size) {
- lib9p_error(&ctx->basectx,
- E_POSIX_EINVAL, "offset is past end-of-file length");
+ lib9p_error(ctx, E_POSIX_EINVAL, "offset is past end-of-file length");
return;
}