summaryrefslogtreecommitdiff
path: root/sys
diff options
context:
space:
mode:
authorcinap_lenrek <cinap_lenrek@felloff.net>2022-10-31 15:43:00 +0000
committercinap_lenrek <cinap_lenrek@felloff.net>2022-10-31 15:43:00 +0000
commita84ffa1accef6e4900a7ff3462e9448574b2fb0a (patch)
tree6495b5b12a3e70c7554ba8d598a116480eeeb17d /sys
parent8b5714139bb0d965eb626f87115964d8dcad04af (diff)
lib9p: double the buffer for /srv/$service
Use a buffer bigger than the name limit of devsrv (127 characters), as this will produce the correct error message when trying to create the srv file instead of silently truncating the buffer before.
Diffstat (limited to 'sys')
-rw-r--r--sys/src/lib9p/post.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/src/lib9p/post.c b/sys/src/lib9p/post.c
index b2134968c..2b4defd99 100644
--- a/sys/src/lib9p/post.c
+++ b/sys/src/lib9p/post.c
@@ -20,7 +20,7 @@ postsrv(Srv *s, char *name)
if(pipe(fd) < 0)
return -1;
if(name != nil){
- char buf[80];
+ char buf[160];
snprint(buf, sizeof buf, "/srv/%s", name);
if((cfd = create(buf, OWRITE|ORCLOSE|OCEXEC, 0600)) < 0