diff options
| author | Bug Magnet <marco.nikic@mullvad.net> | 2025-05-26 11:46:41 +0200 |
|---|---|---|
| committer | Bug Magnet <marco.nikic@mullvad.net> | 2025-06-04 09:51:39 +0200 |
| commit | 877e1c615248a54f0c27dbecb79a3a5289506bda (patch) | |
| tree | 70074aa9d91878d9ae132824dc448c5c671118d5 /ios/MullvadRustRuntime/include | |
| parent | 64862490c2781e4be3b8e77d5c297198fcb63d54 (diff) | |
| download | mullvadvpn-877e1c615248a54f0c27dbecb79a3a5289506bda.tar.xz mullvadvpn-877e1c615248a54f0c27dbecb79a3a5289506bda.zip | |
Add API availability check to mullvad-ios
Diffstat (limited to 'ios/MullvadRustRuntime/include')
| -rw-r--r-- | ios/MullvadRustRuntime/include/mullvad_rust_runtime.h | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/ios/MullvadRustRuntime/include/mullvad_rust_runtime.h b/ios/MullvadRustRuntime/include/mullvad_rust_runtime.h index 08bb177116..66cd2d081f 100644 --- a/ios/MullvadRustRuntime/include/mullvad_rust_runtime.h +++ b/ios/MullvadRustRuntime/include/mullvad_rust_runtime.h @@ -366,6 +366,25 @@ struct SwiftCancelHandle mullvad_ios_get_addresses(struct SwiftApiContext api_co * object `MullvadApiCompletion`. The pointer will be freed by calling `mullvad_api_completion_finish` * when completion finishes (in completion.finish). * + * `retry_strategy` must have been created by a call to either of the following functions + * `mullvad_api_retry_strategy_never`, `mullvad_api_retry_strategy_constant` or `mullvad_api_retry_strategy_exponential` + * + * This function is not safe to call multiple times with the same `CompletionCookie`. + */ +struct SwiftCancelHandle mullvad_ios_api_addrs_available(struct SwiftApiContext api_context, + void *completion_cookie, + struct SwiftRetryStrategy retry_strategy); + +/** + * # Safety + * + * `api_context` must be pointing to a valid instance of `SwiftApiContext`. A `SwiftApiContext` is created + * by calling `mullvad_api_init_new`. + * + * This function takes ownership of `completion_cookie`, which must be pointing to a valid instance of Swift + * object `MullvadApiCompletion`. The pointer will be freed by calling `mullvad_api_completion_finish` + * when completion finishes (in completion.finish). + * * `etag` must be a pointer to a null terminated string. * * `retry_strategy` must have been created by a call to either of the following functions |
