Remove localtime_tz and strftime_tz.
This also brings our copy of strftime.c much closer to upstream, though we still have several GNU extensions and hacks to deal with Android32's broken time_t. Bug: 15765976 Change-Id: Ic9ef36e8acd3619504ecc4d73feec2b61fd4dfa1
This commit is contained in:
@@ -2310,20 +2310,4 @@ __attribute__((visibility("default"))) time_t mktime_tz(struct tm* const tmp, co
|
||||
return return_value;
|
||||
}
|
||||
|
||||
// Non-standard API: localtime(3) but with an explicit timezone parameter.
|
||||
#if !defined(__LP64__)
|
||||
__attribute__((visibility("default"))) void localtime_tz(const time_t* const timep, struct tm* tmp, const char* tz) {
|
||||
struct state* st = malloc(sizeof(*st));
|
||||
|
||||
if (st == NULL)
|
||||
return;
|
||||
if (__bionic_tzload_cached(tz, st, TRUE) != 0) {
|
||||
// TODO: not sure what's best here, but for now, we fall back to gmt.
|
||||
gmtload(st);
|
||||
}
|
||||
localsub(timep, 0L, tmp, st);
|
||||
free(st);
|
||||
}
|
||||
#endif
|
||||
|
||||
// END android-added
|
||||
|
Reference in New Issue
Block a user