mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 19:38:12 +00:00
LibCore: Do not refer to extern int daylight
in DateTime::to_string
This variable does not exist on FreeBSD. Co-Authored-By: Al Hoang <13622+hoanga@users.noreply.github.com>
This commit is contained in:
parent
42e22f89a4
commit
32480fbeb9
1 changed files with 4 additions and 0 deletions
|
@ -251,7 +251,11 @@ String DateTime::to_string(StringView format) const
|
|||
format_time_zone_offset(true);
|
||||
break;
|
||||
case 'Z': {
|
||||
#ifndef __FreeBSD__
|
||||
auto const* timezone_name = tzname[daylight];
|
||||
#else
|
||||
auto const* timezone_name = tzname[0];
|
||||
#endif
|
||||
builder.append({ timezone_name, strlen(timezone_name) });
|
||||
break;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue