mirror of
https://github.com/SideStore/SideStore.git
synced 2026-02-09 06:43:25 +01:00
Add retries in the various minimuxer functions
This commit is contained in:
committed by
Joe Mattiello
parent
7162a029bb
commit
fc6d92d1fc
@@ -146,7 +146,13 @@ class LaunchViewController: RSTLaunchViewController, UIDocumentPickerDelegate
|
||||
|
||||
func start_minimuxer_threads(_ pairing_file: String) {
|
||||
set_usbmuxd_socket()
|
||||
let res = start_minimuxer(pairing_file: pairing_file)
|
||||
var res = start_minimuxer(pairing_file: pairing_file)
|
||||
var attempts = 10
|
||||
while (attempts != 0 && res != 0) {
|
||||
print("start_minimuxer `res` != 0, retry #\(attempts)")
|
||||
res = start_minimuxer(pairing_file: pairing_file)
|
||||
attempts -= 1
|
||||
}
|
||||
if res != 0 {
|
||||
displayError("minimuxer failed to start. Incorrect arguments were passed.")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user