商店仪表板中的一些神奇的 STOWED EXCEPTION
Some magic STOWED EXCEPTION in Store dashboard
我在 Windows 商店中有一个 UWP 应用程序。
通常我在 HockeyApp 中看到约 50 次崩溃,在 Windows 商店运行状况仪表板中看到约 500 次崩溃。
STOWED_EXCEPTION_System.ArgumentException_80070057
Frame Image Function Offset
0 SharedLibrary System::Delegate.InitializeClosedInstance 0x26
1 SharedLibrary System::Action.ConstructClosedInstanceDelegate 0x20
2 XXX.dll XXX::Platform::Uwp::Xaml::XamlApp.OnInitialize 0x301
我的代码很简单
public class XamlApp : Application
{
private Page _page;
protected virtual void OnInitialize(ActivationKind activationKind, ApplicationExecutionState previouState)
{
if (_page == null)
{
_page = _pageCreator();
_page.Loaded += PageOnLoaded;
Current.Suspending += Current_Suspending;
Window.Current.CoreWindow.VisibilityChanged += CurrentOnVisibilityChanged;
Window.Current.Content = _page;
}
else
{
Game.Marshal(Game.Resume);
}
}
// ....
}
根据实施 here 我了解到对对象的引用为空。问题是——怎么可能呢?看起来像是 GC 或运行时某处的错误。
有什么想法吗?
我好尴尬。 10分钟的写题帮助了之前2个多小时的思考。
这是一个正常的异常,这意味着我试图创建一个指向空对象方法的委托。
在我的最后一行代码中,当计算参数并从方法组创建委托时,在方法调用之前发生此异常。
希望这会为某人节省几分钟的时间
我在 Windows 商店中有一个 UWP 应用程序。
通常我在 HockeyApp 中看到约 50 次崩溃,在 Windows 商店运行状况仪表板中看到约 500 次崩溃。
STOWED_EXCEPTION_System.ArgumentException_80070057
Frame Image Function Offset
0 SharedLibrary System::Delegate.InitializeClosedInstance 0x26
1 SharedLibrary System::Action.ConstructClosedInstanceDelegate 0x20
2 XXX.dll XXX::Platform::Uwp::Xaml::XamlApp.OnInitialize 0x301
我的代码很简单
public class XamlApp : Application
{
private Page _page;
protected virtual void OnInitialize(ActivationKind activationKind, ApplicationExecutionState previouState)
{
if (_page == null)
{
_page = _pageCreator();
_page.Loaded += PageOnLoaded;
Current.Suspending += Current_Suspending;
Window.Current.CoreWindow.VisibilityChanged += CurrentOnVisibilityChanged;
Window.Current.Content = _page;
}
else
{
Game.Marshal(Game.Resume);
}
}
// ....
}
根据实施 here 我了解到对对象的引用为空。问题是——怎么可能呢?看起来像是 GC 或运行时某处的错误。
有什么想法吗?
我好尴尬。 10分钟的写题帮助了之前2个多小时的思考。
这是一个正常的异常,这意味着我试图创建一个指向空对象方法的委托。
在我的最后一行代码中,当计算参数并从方法组创建委托时,在方法调用之前发生此异常。
希望这会为某人节省几分钟的时间