Debian Codegraph @

src/vendor/azure-uamqp-c/deps/azure-c-shared-utility/pal/agenttime.c

raw
1 // Copyright (c) Microsoft. All rights reserved.
2 // Licensed under the MIT license. See LICENSE file in the project root for full license information.
3
4 #include "azure_c_shared_utility/gballoc.h"
5
6 #include <time.h>
7 #include "azure_c_shared_utility/agenttime.h"
8
9 time_t get_time(time_t* p)
10 {
11 return time(p);
12 }
13
14 struct tm* get_gmtime(time_t* currentTime)
15 {
16 return gmtime(currentTime);
17 }
18
19 time_t get_mktime(struct tm* cal_time)
20 {
21 return mktime(cal_time);
22 }
23
24 char* get_ctime(time_t* timeToGet)
25 {
26 return ctime(timeToGet);
27 }
28
29 double get_difftime(time_t stopTime, time_t startTime)
30 {
31 return difftime(stopTime, startTime);
32 }