Ping was a static JNI method that loaded the .so before nativeInit, crashing jemalloc. Now ping is an instance method on WzpEngine: - Engine is created once (nativeInit), reused for both ping and call - pingRelay() uses same tokio runtime pattern as startCall() - Auto-pings all servers on app launch (after engine init) - No process restart needed - TOFU fingerprints saved on first successful ping Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
13 lines
295 B
Kotlin
13 lines
295 B
Kotlin
package com.wzp.net
|
|
|
|
// Relay pinging is now done via WzpEngine.pingRelay() (instance method).
|
|
// This file kept for the data class only.
|
|
|
|
object RelayPinger {
|
|
data class PingResult(
|
|
val rttMs: Int,
|
|
val reachable: Boolean,
|
|
val serverFingerprint: String = "",
|
|
)
|
|
}
|