• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2003, Intel Corporation. All rights reserved.
3  * Created by:  majid.awad REMOVE-THIS AT intel DOT com
4  * This file is licensed under the GPL license.  For the full content
5  * of this license, see the COPYING file at the top level of this
6  * source tree.
7  *
8  *
9  * The gmtime function shall return a pointer to struct tm.
10  *
11  */
12 
13 #include <stdio.h>
14 #include <time.h>
15 #include <posixtest.h>
16 
main(void)17 int main(void)
18 {
19 	struct tm *tm_ptr;
20 	time_t the_time;
21 
22 	(void)time(&the_time);
23 	tm_ptr = NULL;
24 	tm_ptr = gmtime(&the_time);
25 
26 	if (tm_ptr != NULL) {
27 		puts("Test PASSED");
28 		return PTS_PASS;
29 	} else {
30 		puts("Test FAILED");
31 		return PTS_FAIL;
32 	}
33 }
34