[RE] Fix the keystroke-swallow log against upstream's XamState
Some checks failed
Orchestrator / Commit Message Validation (push) Has been skipped
Orchestrator / Lint (push) Failing after 2m24s
Orchestrator / Windows (x86-64) (push) Has been skipped
Orchestrator / Linux (x86-64) (push) Has been skipped
Orchestrator / Create Release (push) Has been skipped

A SILENT semantic conflict from merging auto/re-kernel-pages-probe: git merged
every file cleanly and the result did not compile. The RE aid added by
043002a87 prints the dialog counters

  xam_dialogs_shown_ / xam_nui_dialogs_shown_

which upstream has since collapsed into a single is_xam_dialog_present_ flag,
reachable only through IsUIActive(). The counts no longer exist, so report the
state that does -- which is what the message is actually about.

Worth noting for the next merge of this fork: a clean `git merge` is not
evidence that instrumentation still matches the API it reads. Build it.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
This commit is contained in:
Sylpheed RE agent
2026-08-28 15:48:38 +02:00
parent ff46ec87a4
commit 590912722c

View File

@@ -204,11 +204,15 @@ dword_result_t XamInputGetKeystrokeEx_entry(
static std::atomic<uint32_t> swallowed{0};
const uint32_t n = swallowed.fetch_add(1, std::memory_order_relaxed);
if ((n % 600) == 0) {
// Upstream replaced the two counters this used to print
// (xam_dialogs_shown_ / xam_nui_dialogs_shown_) with a single
// is_xam_dialog_present_ flag, reachable only through IsUIActive(). The
// counts are gone, so report the state that remains — which is the thing
// the message is actually about.
XELOGW(
"[RE-INPUT] XamInputGetKeystrokeEx swallowed by IsUIActive "
"(dialogs={} nui={}, {} so far)",
kernel_state()->xam_state()->xam_dialogs_shown_.load(),
kernel_state()->xam_state()->xam_nui_dialogs_shown_.load(), n + 1);
"(ui_active={}, {} so far)",
kernel_state()->xam_state()->IsUIActive(), n + 1);
}
return X_ERROR_SUCCESS;
}