Skip to content

Instantly share code, notes, and snippets.

@paddya
Created November 10, 2012 15:52
Show Gist options
  • Save paddya/4051455 to your computer and use it in GitHub Desktop.
Save paddya/4051455 to your computer and use it in GitHub Desktop.
char* getTime()
{
struct timeval time;
static char timeString[30];
gettimeofday(&time, NULL);
strftime(timeString, 30, "%d.%m.%Y - %H:%M:%S", localtime(&time.tv_sec));
return timeString;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment