From: Maik Fischer Date: Sun, 29 Oct 2017 18:01:04 +0000 (+0100) Subject: itemz: fix int16_t -> uint8_t truncation X-Git-Tag: rgb2rv17~9^2~2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=d57cddb94b24c1972e5464c63b0529a44fd419aa;p=c128-kasse itemz: fix int16_t -> uint8_t truncation --- diff --git a/src/itemz.c b/src/itemz.c index 574705a..7cf8ea6 100644 --- a/src/itemz.c +++ b/src/itemz.c @@ -74,10 +74,12 @@ static void _delete_item(BYTE num) { } static void delete_item(void) { - BYTE num, last; - + int16_t num; + uint8_t last; cprintf("\r Welcher Eintrag soll geloescht werden?\r\n"); - if ((num = cget_number(-1)) < 0) + + num = cget_number(-1); + if (num < 0) return; if (status.num_items > 1) {