colors

extract colors from pictures
git clone git://git.2f30.org/colors
Log | Files | Refs | README | LICENSE

commit 30fe2f428d737c5c00c1a7b3d60ec4256e4a628d
parent c0705d6620aadbc782327f41bd6e3a0f0a08b28e
Author: sin <sin@2f30.org>
Date:   Fri,  5 Jun 2015 15:40:36 +0100

Don't segfault if nclusters is 0

Diffstat:
Mcolors.c | 2+-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/colors.c b/colors.c @@ -250,7 +250,7 @@ main(int argc, char *argv[]) case 'n': errno = 0; nclusters = strtol(EARGF(usage()), &e, 10); - if (*e || errno) + if (*e || errno || !nclusters) errx(1, "invalid number"); break; default: