https://bugs.winehq.org/show_bug.cgi?id=48290
Bug ID: 48290 Summary: SharpDevelop exception in debugger Product: Wine Version: 5.0-rc1 Hardware: x86 OS: Linux Status: UNCONFIRMED Severity: normal Priority: P2 Component: -unknown Assignee: wine-bugs@winehq.org Reporter: 3dw_50ssu16amyn7@byom.de Distribution: ---
Created attachment 65987 --> https://bugs.winehq.org/attachment.cgi?id=65987 example project with reproduction code
Using SharpDevelop 5.1 and running the following code with the debugger results in an error not handled by the debugger but the catch clause from SharpDevelop.
var assembly = Assembly.GetExecutingAssembly(); using (Stream stream = assembly.GetManifestResourceStream("NonExistentResource")) { using (var reader = new StreamReader(stream)) { reader.ReadToEnd(); }}
On Windows the debugger catches the error correctly.
Steps to reproduce: - Install dotnet45, vcrun2008 and SharpDevelop - download project/insert above code in SharpDevelop - Compile and run with debugger (press F9) - Error should be catched by the debugger like on Windows
Relevant log lines: ERROR- ThreadException caught System.Runtime.InteropServices.COMException (0x80004005): Error HRESULT E_FAIL has been returned from a call to a COM component. ... (see log)
SharpDevelop 5.1 download: https://sourceforge.net/projects/sharpdevelop/files/SharpDevelop%205.x/5.1/
https://bugs.winehq.org/show_bug.cgi?id=48290
--- Comment #1 from sahelanthropus 3dw_50ssu16amyn7@byom.de --- Created attachment 65988 --> https://bugs.winehq.org/attachment.cgi?id=65988 log output with exception at end
https://bugs.winehq.org/show_bug.cgi?id=48290
--- Comment #2 from sahelanthropus 3dw_50ssu16amyn7@byom.de --- Note that installing dotnet45 or vcrun2008 sets the Windows version to another value and isn't restored, so setting the os version to Win 7 or higher is required to install SharpDevelop.
Also the key to compile and run with debugger is F5 instead of F9.
https://bugs.winehq.org/show_bug.cgi?id=48290
sahelanthropus 3dw_50ssu16amyn7@byom.de changed:
What |Removed |Added ---------------------------------------------------------------------------- Distribution|--- |Ubuntu
https://bugs.winehq.org/show_bug.cgi?id=48290
--- Comment #3 from sahelanthropus 3dw_50ssu16amyn7@byom.de --- Forgot to mention I tested with wine 4.21 and wine-staging 5.0-rc1 on Ubuntu 18.04.3
More ways to create the same exception:
"".Remove(1); // remove more than is in string
or
foreach (int x in new Object[2]) {} // cast object as int
https://bugs.winehq.org/show_bug.cgi?id=48290
Damjan Jovanovic damjan.jov@gmail.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |damjan.jov@gmail.com
--- Comment #4 from Damjan Jovanovic damjan.jov@gmail.com --- I can't even get that far. Building gives me:
Source file 'C:\users\user\Temp.NETFramework,version=4.0.AssemblyAttributes.cs' could not be found (CS2001).
https://bugs.winehq.org/show_bug.cgi?id=48290
--- Comment #5 from sahelanthropus 3dw_50ssu16amyn7@byom.de --- If there's no access restriction on the temp folder you could try setting the key TargetFrameworkVersion in C.csproj to "v4.5" or installing dotnet40 if its not already installed. I may set the wrong target version.