1 #define _POSIX_PTHREAD_SEMANTICS // needed for Solaris for asctime_r
8 /* Prints a time on a single line of the console.
9 * I wrote this app so that I could measure times by repeatedly pressing
14 void strip_newlines(char *str)
17 size_t str_len = strlen(str);
19 for (i = 0; i < str_len; i++) {
29 time_t t = time(NULL);
30 struct tm *tm = localtime(&t);