debug
This commit is contained in:
parent
d3da26f037
commit
477ba6cddc
13
main.c
13
main.c
@ -243,16 +243,13 @@ int main(int argc,char **argv,char** envp)
|
|||||||
char date[60];
|
char date[60];
|
||||||
time_t now ;
|
time_t now ;
|
||||||
char * locale;
|
char * locale;
|
||||||
|
char * language;
|
||||||
|
char * ptr;
|
||||||
|
|
||||||
char** env;
|
language = getenv("LANGUAGE");
|
||||||
for(env=envp;*env!=0;env++)
|
ptr = strtok (language, ":");
|
||||||
{
|
|
||||||
char* thisEnv = *env;
|
|
||||||
printf("%s\n",thisEnv);
|
|
||||||
}
|
|
||||||
|
|
||||||
locale = setlocale(LC_ALL,"");
|
locale = setlocale(LC_ALL,"");
|
||||||
locale = setlocale(LC_ALL,NULL);
|
locale = setlocale(LC_ALL,ptr);
|
||||||
time( &now );
|
time( &now );
|
||||||
sprintf( date, "%s", ctime(&now));
|
sprintf( date, "%s", ctime(&now));
|
||||||
date[strlen(date)-1] = 0;
|
date[strlen(date)-1] = 0;
|
||||||
|
Reference in New Issue
Block a user