]> git.sur5r.net Git - c128-kasse/commitdiff
include time in paper trail when adding a new credit
authorMichael Stapelberg <michael@stapelberg.de>
Sat, 29 Sep 2012 15:30:39 +0000 (17:30 +0200)
committerMichael Stapelberg <michael@stapelberg.de>
Sat, 29 Sep 2012 15:30:39 +0000 (17:30 +0200)
src/credit_manager.c

index 8230890c3382964644747d4bbd5c42d10b1c789f..a76c128c69ad17d7c95571ea974647636a912107 100644 (file)
@@ -92,6 +92,7 @@ void deposit_credit(char *input) {
 
 static void new_credit() {
        char *input, *name;
+       char *time;
        int credit;
 
        if (credits.num_items == 75) {
@@ -111,7 +112,8 @@ static void new_credit() {
        strcpy(credits.credits[credits.num_items].nickname, name);
        credits.credits[credits.num_items].credit = credit;
 
-       sprintf(print_buffer, "%cGuthaben mit %d Cent fuer %s angelegt\r", 17, credit, name);
+       time = get_time();
+       sprintf(print_buffer, "%c%s - Guthaben mit %d Cent fuer %s angelegt\r", 17, time, credit, name);
        print_the_buffer();
 
        credits.num_items++;