This commit is contained in:
Logan McNaughton
2026-06-06 22:26:49 +02:00
parent 1e337b8540
commit e0e1db4482
2 changed files with 4 additions and 4 deletions
+2 -2
View File
@@ -219,7 +219,7 @@ pub fn run(args: Args, arg_count: usize) -> std::io::Result<()> {
ra_config.leaderboard,
);
let (tx, mut rx) = tokio::sync::oneshot::channel::<bool>();
let (tx, rx) = tokio::sync::oneshot::channel::<bool>();
if let Some(password) = args.ra_password {
retroachievements::login_user(username, password, tx);
} else if !ra_config.token.is_empty() {
@@ -228,7 +228,7 @@ pub fn run(args: Args, arg_count: usize) -> std::io::Result<()> {
tx.send(false).unwrap();
}
while rx.try_recv().is_err() {}
rx.blocking_recv().unwrap();
ra_config
} else {
+2 -2
View File
@@ -145,12 +145,12 @@ pub fn load_game(
Option<tokio::sync::watch::Sender<()>>,
Option<tokio::task::JoinHandle<()>>,
) {
let (tx, mut rx) = tokio::sync::oneshot::channel::<bool>();
let (tx, rx) = tokio::sync::oneshot::channel::<bool>();
unsafe {
let tx_ptr = Box::into_raw(Box::new(tx)) as *mut std::ffi::c_void;
ra_load_game(rom.as_ptr(), rom_size, tx_ptr);
};
while rx.try_recv().is_err() {}
rx.blocking_recv().unwrap();
let mut c_title = std::ptr::null();
let mut c_image_url = std::ptr::null();