SARDONYX-sard / dar-to-oar

DAR to OAR Converter for SkyrimSE(dar2oar)
https://www.nexusmods.com/skyrimspecialedition/mods/101822
Apache License 2.0
3 stars 1 forks source link

[Bug](Core): Err skipping is unsafe. #11

Closed SARDONYX-sard closed 1 year ago

SARDONYX-sard commented 1 year ago

Version

0.1.5

Unexpected behavior here

It does not return an error even if it never performs a conversion. https://github.com/SARDONYX-sard/dar-to-oar/blob/330041f1de0b8bd0cb59fb063e5a2d622b822c0f/dar2oar_core/src/fs/sequential/mod.rs#L29

Expected behavior

Returns an error if the conversion was never performed. But I don't know how to construct that flag (should I just use an AtomicBool?).

static IS_CONVERTE_EXECUTED_ONCE: AtomicBool = AtomicBool(false);

if !IS_CONVERTE_EXECUTED_ONCE.load(Ordering::Acquire) {
    bail!("DynamicAnimationReplacer dir was never found")
}

Relevant log output

No response

SARDONYX-sard commented 1 year ago

Fixed by (#12)