summary refs log tree commit diff
path: root/net.c
diff options
context:
space:
mode:
authorwrmr2024-11-08 23:30:42 -0500
committerwrmr2024-11-08 23:30:42 -0500
commitcd3626642755359eecf64d05e3f9db3d8b00ed24 (patch)
treee7270b2c779c7aeb0c1b88ed2dee67d4c264854a /net.c
parent012ed5bd6455ce291741ad540a5e356e4810133b (diff)
use strv_t even more
Diffstat (limited to 'net.c')
-rw-r--r--net.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/net.c b/net.c
index b3f0655..0d6604e 100644
--- a/net.c
+++ b/net.c
@@ -132,7 +132,7 @@ static int fetch_file(const struct addr *adr, struct buf *buf, enum doc_type *do
 	buf_init(buf, 1024);
 	char b[256];
 	while (fgets(b, sizeof b, f)) {
-		buf_cat(buf, b, strlen(b));
+		buf_cat(buf, strv(b));
 	}
 	buf_catc(buf, 0);
 	fclose(f);
@@ -184,7 +184,7 @@ static int fetch_gopher(const struct addr *adr, struct buf *buf, enum doc_type *
 			return -1;
 		}
 		if (!n) break;
-		buf_cat(buf, inbuf, n);
+		buf_cat(buf, (strv_t) { inbuf, n });
 	}
 	close(s);
 	return 0;