[XAM] Limit XContentQueryVolumeDeviceType to XContent packages
Some checks failed
Orchestrator / Commit Message Validation (push) Has been skipped
Orchestrator / Lint (push) Successful in 1m23s
Orchestrator / Windows (x86-64) (push) Failing after 5m18s
Orchestrator / Linux (x86-64) (push) Failing after 22m34s
Orchestrator / Create Release (push) Has been skipped

- Changed mount path for XContent packages from Cdrom to Package_0
Normally it should generate specific value instead of 0, but for now 0 is enough
This commit is contained in:
Gliniak
2026-06-05 13:27:45 +02:00
committed by Radosław Gliński
parent 9478cda5d6
commit 99fd19d025
2 changed files with 12 additions and 1 deletions

View File

@@ -111,6 +111,17 @@ X_HRESULT XamApp::DispatchMessageSync(uint32_t message, uint32_t buffer_ptr,
}* data = reinterpret_cast<XContentQueryVolumeDeviceType*>(buffer);
assert_true(buffer_length == sizeof(XContentQueryVolumeDeviceType));
std::string target;
if (!kernel_state_->file_system()->FindSymbolicLink(
std::string(data->root_name) + ':', target)) {
return X_E_INVALIDARG;
}
// Only apply this check to XContent packages
if (!target.starts_with("\\Device\\Package_")) {
return X_E_INVALIDARG;
}
xe::be<DeviceType>* device_type_ptr =
memory_->TranslateVirtual<xe::be<DeviceType>*>(
static_cast<uint32_t>(data->device_type_ptr.get()));