Commit aa6c0b5105c8829f3ab30f081fa2d3d68ac674d1

Stefan Sperling 2019-09-22T10:35:16

remove unused variable in got_privsep_recv_obj() (patch by Steven McDonald)

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
diff --git a/lib/privsep.c b/lib/privsep.c
index f9961bf..62a79cf 100644
--- a/lib/privsep.c
+++ b/lib/privsep.c
@@ -430,7 +430,6 @@ got_privsep_recv_obj(struct got_object **obj, struct imsgbuf *ibuf)
 {
 	const struct got_error *err = NULL;
 	struct imsg imsg;
-	size_t datalen;
 	const size_t min_datalen =
 	    MIN(sizeof(struct got_imsg_error), sizeof(struct got_imsg_object));
 
@@ -440,8 +439,6 @@ got_privsep_recv_obj(struct got_object **obj, struct imsgbuf *ibuf)
 	if (err)
 		return err;
 
-	datalen = imsg.hdr.len - IMSG_HEADER_SIZE;
-
 	switch (imsg.hdr.type) {
 	case GOT_IMSG_OBJECT:
 		err = got_privsep_get_imsg_obj(obj, &imsg, ibuf);