xref: /aosp_15_r20/external/compiler-rt/test/msan/tzset.cc (revision 7c3d14c8b49c529e04be81a3ce6f5cc23712e4c6)
1 // RUN: %clangxx_msan -O0 %s -o %t && %run %t
2 
3 #include <stdlib.h>
4 #include <string.h>
5 #include <time.h>
6 
7 extern char *tzname[2];
8 
main(void)9 int main(void) {
10   if (!strlen(tzname[0]) || !strlen(tzname[1]))
11     exit(1);
12   tzset();
13   if (!strlen(tzname[0]) || !strlen(tzname[1]))
14     exit(1);
15   return 0;
16 }
17