File tree 2 files changed +2
-2
lines changed 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -64,6 +64,6 @@ internal actual fun currentSystemDefaultZone(): RegionTimeZone {
64
64
*/
65
65
NSTimeZone .resetSystemTimeZone()
66
66
val zone = NSTimeZone .systemTimeZone
67
- val zoneId = zone.name ? : throw IllegalStateException ( " Failed to get the system timezone " )
67
+ val zoneId = zone.name
68
68
return RegionTimeZone (systemTzdb.rulesForId(zoneId), zoneId)
69
69
}
Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ private fun isValidInstantSecond(second: Long) = second >= MIN_SECOND && second
134
134
135
135
internal fun currentTime (): Instant = memScoped {
136
136
val tm = alloc< timespec> ()
137
- val error = clock_gettime(CLOCK_REALTIME , tm.ptr)
137
+ val error = clock_gettime(CLOCK_REALTIME .convert() , tm.ptr)
138
138
check(error == 0 ) { " Error when reading the system clock: ${strerror(errno)} " }
139
139
try {
140
140
require(tm.tv_nsec in 0 until NANOS_PER_ONE )
You can’t perform that action at this time.
0 commit comments