summaryrefslogtreecommitdiff
path: root/src/bin/ethumb_client/ethumbd_slave.c
diff options
context:
space:
mode:
authorCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-09-19 23:15:44 +0100
committerCarsten Haitzler (Rasterman) <raster@rasterman.com>2020-09-19 23:15:44 +0100
commitec4076b8959ff50033a2131a4fd51eaa57ea7e4f (patch)
tree73592a53b81e0f77adabe4ea3a3be42effa24a6e /src/bin/ethumb_client/ethumbd_slave.c
parentd64d4568bd601dbf7081ff5abed1c9075a2ad08a (diff)
ethumb - fix idx range check
fix CID 1402612
Diffstat (limited to '')
-rw-r--r--src/bin/ethumb_client/ethumbd_slave.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/bin/ethumb_client/ethumbd_slave.c b/src/bin/ethumb_client/ethumbd_slave.c
index c09c4ced5d..1b805a4bd3 100644
--- a/src/bin/ethumb_client/ethumbd_slave.c
+++ b/src/bin/ethumb_client/ethumbd_slave.c
@@ -183,6 +183,8 @@ _ec_op_new(struct _Ethumbd_Child *ec)
183 r = _ec_read_safe(stdin, &idx, sizeof(idx)); 183 r = _ec_read_safe(stdin, &idx, sizeof(idx));
184 if (!r) 184 if (!r)
185 return 0; 185 return 0;
186 if ((idx < 0) || (idx >= NETHUMBS))
187 return 0;
186 188
187 DBG("ethumbd new(). idx = %d", idx); 189 DBG("ethumbd new(). idx = %d", idx);
188 190