projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Port: replace setenv() by g_setenv()
[babeltrace.git]
/
include
/
babeltrace
/
compat
/
utc-internal.h
diff --git
a/include/babeltrace/compat/utc-internal.h
b/include/babeltrace/compat/utc-internal.h
index d78a1885203764f9830dca11b98eccbfb5d0a173..db3035a3ad6ec51b65270e2cbb49c062910e1d1c 100644
(file)
--- a/
include/babeltrace/compat/utc-internal.h
+++ b/
include/babeltrace/compat/utc-internal.h
@@
-46,6
+46,7
@@
time_t bt_timegm(struct tm *tm)
#include <string.h>
#include <stdlib.h>
#include <string.h>
#include <stdlib.h>
+#include <glib.h>
/*
* Note: Below implementation of timegm() is not thread safe
/*
* Note: Below implementation of timegm() is not thread safe
@@
-76,11
+77,11
@@
time_t bt_timegm(struct tm *tm)
}
/* Temporarily setting TZ to 1 for UTC */
}
/* Temporarily setting TZ to 1 for UTC */
- setenv("TZ", "", 1);
+
g_
setenv("TZ", "", 1);
tzset();
ret = mktime(tm);
if (tz) {
tzset();
ret = mktime(tm);
if (tz) {
- setenv("TZ", tz, 1);
+
g_
setenv("TZ", tz, 1);
free(tz);
} else {
unsetenv("TZ");
free(tz);
} else {
unsetenv("TZ");
This page took
0.022845 seconds
and
4
git commands to generate.