simple_time.c: fix set-but-not-used warning
authorColin Patrick Mccabe <cmccabe@alumni.cmu.edu>
Sat, 12 Jan 2013 19:38:37 +0000 (11:38 -0800)
committerColin Patrick Mccabe <cmccabe@alumni.cmu.edu>
Sat, 12 Jan 2013 19:38:37 +0000 (11:38 -0800)
Signed-off-by: Colin McCabe <cmccabe@alumni.cmu.edu>

simple_time.c

index 5906409..9bede48 100644 (file)
@@ -24,13 +24,11 @@ int main(void)
 {
        while (1) {
                char str[27];
-               size_t len;
                time_t t = time(NULL);
                struct tm *tm = localtime(&t);
 
                str[0] = '\0';
                asctime_r(tm, str);
-               len = strlen(str);
                printf("\r");
                strip_newlines(str);
                printf("%s", str);