Exception in RuntimeBroker on UWP app startup


C# UWP project with a native component in C++, targeting Windows 10 14393, Visual Studio 2019. Running the 32-bit build. On one machine (Windows 10 x64), it runs fine. On another machine (also Windows 10 x64), during startup, it pop up a JIT debugger window:

"An unhandled win32 exception occurred in [204976] RuntimeBroker.exe."

and a choice of debuggers.

If you click "Cancel", the UWP app in question starts as it should. If you choose to debug, the exception is:

Unhandled exception at 0x00007FFC1025362A (Windows.ApplicationModel.Store.dll) in RuntimeBroker.exe: 0xC0000005: Access violation reading location 0x0000000000000000.

EDIT: it crashes when the following fragment is executed:

IReadOnlyDictionary<string, ProductLicense> ld = CurrentApp.LicenseInformation.ProductLicenses;
//Which of the ProdIDs are purchased?
bool[] Actives = ProdIDs.Select(
                pid => ld.ContainsKey(pid) && ld[pid].IsActive).ToArray();

The ld is not null, but when ContainsKey is called, the crash happens and the app throws an exception. The application is not on the store yet, so there are no in-app products registered. I don't expect this call to return anything sensible, but still, not cool.

asked on Stack Overflow Jan 7, 2020 by Seva Alekseyev • edited Jan 7, 2020 by Seva Alekseyev

0 Answers

Nobody has answered this question yet.

User contributions licensed under CC BY-SA 3.0