LP7 Upgrade: Could not obtain startup pointer
I upgraded my LinqPad to 7.5.14 (x64) today, but I'm having a lot of issues with it. After some experimenting, I have these reproducable steps:
- Run LINQPad7Setup.exe to install 7.5.14 (x64).
- After finishing the install, allow it to launch LinqPad.
- Run a script that uses a library that references System.Data.SqlClient. This script ran yesterday just fine, but today it does not. It gives the error: "Could not load file or assembly 'System.Data.SqlClient, Version=0.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a'. The system cannot find the...".
- Exit LinqPad.
- Click the LinqPad icon in the system tray. LinqPad doesn't launch, and instead gives you a dialog that says: "Could not obtain startup pointer (-21470248941).".
In order to run LinqPad again, I have to install it again.
Comments
-
Are you still able to reproduce this error? And are you certain that it occurs only after running a particular script?
-
Exactly around that time I started getting that problem too. It appears anytime you close the linqpad and reopen it will throw that startup pointer error. I also upgraded to the latest version
-
Are you able to check the permissions on the LINQPad.GUI.dll and LINQPad.Runtime.dll files, and also verify that they are not in use? If the condition is reproducible, could you take a copy of the folder and send it to me so I can investigate.
You might also like to try 7.5.16 which has just been released:
https://www.linqpad.net/linqpad7.aspx#betaIt includes a bunch of built-in diagnostics in the launchers (on the unmanaged side) to detect and report various error conditions, including
- Missing LINQPad.GUI.dll or LINQPad.Runtime.dll
- Lack of read permission on either of these files
- Lack of execute permission on LINQPad.GUI.dll
- Sharing violation due to a write-lock on either file
- Corruption in either of these files preventing CLR startup
It also writes more information to the log file. If this occurs with 7.5.16, please post the data that's written to %localappdata%\LINQPad\Logs.LINQPad7\startup.txt
-
It is like kneepadsgelding said, every time I close LinqPad7 and reopen it, it throws the startup pointer error.
I see these errors in the startup.txt log file in Logs.LINQPad7:
2022-11-21 09:18:57 Error: Could not obtain startup pointer (-2147024891)
Target DLL: C:\Program Files\LINQPad7\LINQPad.GUI.dll
dotnet root detected via registry: C:\Program Files\dotnet\
Probing C:\Program Files\dotnet\host\fxr
Probing C:\Program Files\dotnet\shared\Microsoft.NETCore.app
Probing C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App
Using dotnet root: C:\Program Files\dotnet\
AllowPrerelease=true
Searching C:\Program Files\dotnet\host\fxr...
- found 7.0.0
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.NETCore.app...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Fxr path: C:\Program Files\dotnet\host\fxr
Best desktop version: 6.0.112022-11-21 09:21:09 0,-2146885629,0
2022-11-21 09:24:20 Error: File 'C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.GUI.dll' does not exist
Target DLL: C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.GUI.dll
dotnet root detected via registry: C:\Program Files\dotnet\
Probing C:\Program Files\dotnet\host\fxr
Probing C:\Program Files\dotnet\shared\Microsoft.NETCore.app
Probing C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App
Using dotnet root: C:\Program Files\dotnet\
AllowPrerelease=true
Searching C:\Program Files\dotnet\host\fxr...
- found 7.0.0
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.NETCore.app...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Fxr path: C:\Program Files\dotnet\host\fxr
Best desktop version: 6.0.11
File 'C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.Runtime.dll' is present and readable2022-11-21 09:25:14 0,-2146885629,0
2022-11-21 09:32:42 Error: Could not obtain startup pointer (-2147024891)
Target DLL: C:\Program Files\LINQPad7\LINQPad.GUI.dll
dotnet root detected via registry: C:\Program Files\dotnet\
Probing C:\Program Files\dotnet\host\fxr
Probing C:\Program Files\dotnet\shared\Microsoft.NETCore.app
Probing C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App
Using dotnet root: C:\Program Files\dotnet\
AllowPrerelease=true
Searching C:\Program Files\dotnet\host\fxr...
- found 7.0.0
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.NETCore.app...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Fxr path: C:\Program Files\dotnet\host\fxr
Best desktop version: 6.0.112022-11-21 09:33:33 Error: File 'C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.GUI.dll' does not exist
Target DLL: C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.GUI.dll
dotnet root detected via registry: C:\Program Files\dotnet\
Probing C:\Program Files\dotnet\host\fxr
Probing C:\Program Files\dotnet\shared\Microsoft.NETCore.app
Probing C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App
Using dotnet root: C:\Program Files\dotnet\
AllowPrerelease=true
Searching C:\Program Files\dotnet\host\fxr...
- found 7.0.0
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.NETCore.app...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Searching C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App...
- found 7.0.0
- found 3.1.31
- found 5.0.17
- found 6.0.11
Fxr path: C:\Program Files\dotnet\host\fxr
Best desktop version: 6.0.11
File 'C:\Users\XXX\AppData\Local\LINQPad\Updates7.AnyCPU\7.5.16\LINQPad.Runtime.dll' is present and readable2022-11-21 09:34:25 0,-2146885629,0
2022-11-21 09:50:46 0,-2146885629,0
-
I've been working on this some more. I downloaded the 7.5.16 beta, and the problem persists.
- I run LINQPad, and it runs fine and I can run my scripts.
- I close LINQPad. When the app closes, I lose read permissions on the file LINQPad.GUI.dll.
- When I try to open LINQPad again, it gives me an error that it can’t find LINQPad.GUI.dll.
- I replace the LINQPad.GUI.dll from the zip that I downloaded. First I get the security dialog that asks for admin permission to put a file in the Program Files path. I click Continue, and then it asks if I want to over-write the file. I click Replace, and it copies the file. I can then run LINQPad again, but when I close it, I can’t access LINQPad.GUI.dll anymore.
I kept the LINQPad folder open on my second monitor when I ran LINQPad. Just after I closed the program, the LINQPad.GUI.dll file in the LINQPad folder turned gray. I viewed the properties of this file and it showed that this file had Deny to Everyone for Traverse folder/execute.
My network admin told me this morning that he received a Cylance security alert about LinqPad, but I'm still waiting to hear back from him to find out what that was about.
-
My network admin finally got back to me. Our antivirus thinks that LINQPad.GUI.dll is suspicious so it keeps quarantining it.
Adding it to the safe list should resolve this issue.
-
Thanks for the update. I'll tweak the launchers to offer hints about antivirus software when this condition is detected.