From 565b76aa595b6a9ed43219b590cf2e10afcf7e9a Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Sat, 28 Mar 2009 11:00:23 -0700 Subject: [PATCH 1/1] Recognize '-' as a numeric characeter as well Without this fix, mnemon would croak when encountering a negative score in a data file, (which can happen after quitting with some unlearned items). --- mnemon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mnemon.c b/mnemon.c index ac7c765..33f2c26 100644 --- a/mnemon.c +++ b/mnemon.c @@ -578,7 +578,7 @@ mnemon_load_category (mnemon_t *mnemon, /* An initial digit means we hit an item. Trigger the * spaghetti machine. */ - if (*line >= '0' && *line <= '9') + if ((*line >= '0' && *line <= '9') || *line == '-') goto PARSE_BIN; equal = strchr (line, '='); -- 2.43.0