oboeru

a collection of simple, scriptable flashcard programs
git clone anongit@rnpnr.xyz:oboeru.git
Log | Files | Refs | Feed | README | LICENSE

Commit: 238f0075edd1cf60918cfa7a17fb1b94aed8f79e
Parent: 4d637ac454e7b35a51d2bd93fcba8dcdea8a9ce0
Author: Randy Palamar
Date:   Tue, 24 Aug 2021 08:34:45 -0600

oboeru: check for cflag before reviews == NULL

Diffstat:
Moboeru.c | 9+++++----
1 file changed, 5 insertions(+), 4 deletions(-)

diff --git a/oboeru.c b/oboeru.c @@ -348,10 +348,6 @@ main(int argc, char *argv[]) } reviews = mkreviews(head); - if (reviews == NULL) { - cleanup(head, decks, reviews); - die("mkreviews()\n"); - } if (cflag) { cleanup(head, decks, reviews); @@ -359,6 +355,11 @@ main(int argc, char *argv[]) return 0; } + if (reviews == NULL) { + cleanup(head, decks, reviews); + die("mkreviews()\n"); + } + shuffle_reviews(reviews, n_reviews); reviews = review_loop(reviews, decks, fifo);