We needed to change the IP address for users at a company for a switch over.
The following has affected about half their PCs and some but not all the Windows logins on a remote desktop server.
When trying to use the atecfg dialog I pressed the Configure button and the Configure dialog pops up with no details in it apart from a login time then disappears after a tiny bit of blue circle cursor (maybe 1 sec). There is an app crash (below) in Event Viewer. This is Windows 10 different PCs mostly but not all at the latest Windows 10.
I put on my Bodger McBogerson hat and managed to get an interim solution by directly importing a registry tree myself. This worked but of course they can't make any changes to it.
Things I tried:
Full uninstall, delete manually all the registry entries. Re-install. Exactly the same problem. The registry entries that I deleted were in the SOFTWARE/Wow3264Node/Microsabio. I bodged in mine to just SOFTWARE/Microsabio Running as Admin,not admin, Local Admin with no difference. Hunted through the other profiles on the PC and got rid of all Microsabio entries. Changed the permissions on C:\ATE to full access for everyone (and the User)
ashlog.log on the PC just shows the atecfg dialog starting but then nothing as it crashes.
Any ideas?
Dominic
Sample Appcrash: Faulting application name: ashw32.exe, version: 6.5.1673.0, time stamp: 0x5df86b62 <-------tried slightly older and new versions up to 1691.2 but no difference. Faulting module name: ashw32.exe, version: 6.5.1673.0, time stamp: 0x5df86b62 Exception code: 0xc0000005 Fault offset: 0x000715d8 Faulting process ID: 0x1f6c Faulting application start time: 0x01d87e6145b9f2b1 Faulting application path: C:\ATE\bin\ashw32.exe Faulting module path: C:\ATE\bin\ashw32.exe Report ID: 7ca4bdbc-4ceb-4642-95c2-13f0b5b0246a Faulting package full name: Faulting package-relative application ID:
I'm not aware of this problem having affected anyone else, and don't have any great ideas yet of what the issue is. But I do have an idea for how to gather more information and possibly pinpoint where the offending operation is (probably a call into a Windows DLL function)...
Edit your C:\ATE\MIAME.INI file and add TRACE=GUI,XCALL,XDEBUG
At least then your C:\ATE\ASHLOG.LOG file should log all of the XCALLs and GUI control creation operations leading up to the crash, which hopefully will produce something like a smoking gun.
That was actually very helpful. And fortunately, unlike in the old days where you had to sit through the entire movie to find out who done it, here we can just skip to the end of the log file. The crash occurs within WINPTRLST.SBX, called by ATECFX.SBX, called by TELNET.LIT. WINPTRLST.SBX uses DYNLIB to enumerate available printers using a function EnumPrinters() which is exposed within the Windows dynamic library module WINSPOOL.DRV. The actual point of failure is a call into a DYNLIB utility function to dereference a raw memory pointer returned by the EnumPrinters() function...
The first line is the call into EnumPrinters(). The second line is a trace of the trace message indicating that it found 11 printers. It then proceeds through the array of printers, converting the structure returned by EnumPrinters (an array of pointers to actual printer names) into a more traditional array of strings. The last line is the attempt to copy the string at memory location 26928340 into an S64 string variable, and that's where it crashes.
So we know who done it, but still don't understand the motivation, i.e. is the memory location returned by EnumPrinters invalid? Or is the DYNLIB utility function to dereference failing for some other reason? And why is is just showing up now in this one environment?
I propose a the following steps to further the investigation:
1) Since there have been some refinements to the DYNLIB subroutine recently, I suggest you start with updating your ATE to the 6.5.1717.3 using ate-6.5.1717.3-web-upd.exe (also accessible via Help > Check For Updates from within ATE). If that doesn't just solve it, then...
2) Let's focus on WINPTRLST.SBX, which may be easier to debug from a standard A-Shell/Windows session rather than ATE. (But I recommend you update your A-Shell windows to match, either using the ashw32.exe from ATE or from this link: ash-6.5.1717.4-w32c-upd.zip. Then log to [907,29] within your SOSLIB area (or just create the ppn) and populate it with the test program winptrtst.run and winptrlst.sbx. (This version of WINPTRLST.SBX is slightly newer than the version released with ATE, but only to add a bit more tracing.) SET DEBUG and SET TRACE XCALL ON and SET TRACE XDEBUG ON and then RUN WINPTRTST (hit ENTER to accept the default option) and let's see if that works. If that works, we might try swapping the two versions of WINPTRLST.SBX to see if it's something about the compilation or about ATE vs A-Shell/Windows.
3) If that doesn't solve the crime,then let's take a closer look your WINSPOOL.DRV. I'm assuming that the version that gets loaded is from c:\Windows\SysWOW64, in which case mine is dated 11-May-22 and is 435K. (Oddly, no version is included.) If your is different, maybe send it over?
So I removed 2 Offline printers from the PC an now the config dialog works!!!! I have run the tests again (attached). WINTSTPTR and ashlog now return the same number (10) rather than 10 and 12 printers so maybe there is something to that?
... The odd thing about this is the crash seems to occur in the operation of dereferencing the pointer to the printer name in the structure returned by EnumWindows(). If it had something to do with the status of the printer, it seems like the problem would have occurred in the EnumWindows() call, rather than the conversion of the returned pointers to the printer names. The ashlog shows the pointer/address that it was crashing on (24052610), but unfortunately there is no easy way to determine whether that address was valid.
It's also interesting that the ATE Local Session test (good idea by Mr. Evans) didn't fail. (Am I right in assuming that this was on a PC that otherwise failed when trying to launch the configuration dialog?) In theory the two variations should have had essentially equal results, other than different memory locations in play.
Hmm..., nothing jumps out about those two printer entries being a problem. The p4() structure returned by EnumWindows() is just this:
Code
defstruct ST_PRINTER_INFO_4 ! internal Windows Printer Info type 4
map2 pPrinterName,b,4 ! -> name
map2 pServerName,b,4 ! -> name
map2 Attributes,b,4
endstruct
The address that failed (24052610) is right in line with others in the array that worked in the local test, so it doesn't seem rogue.
The fact that the error occurs on the very first array element (even though your apparent fix involves removing elements 9 and 12) seems to go along with the fact that the local test succeeded even though it had the environment and set of printers as the one that crashes, suggesting that it's some kind of lurking bug just waiting for a particular memory/printer/IP/something configuration to trigger. But since that WINPTRLST.SBX routine hadn't changed since 2017, the set of conditions must be somewhat rare.
If I could figure out how to reproduce it here, I could probably trap it in the VS debugger, but so far no luck with that.
Just thought I would let you know that removing the offline printers (the same printers of course as they were shared from their server) has now worked on all PCs that I had left to fix.
A quick update to remind myself more than anything. A new PC was put in at the same company and the two offending printers were on it, but NOT showing offline. However, I still had to remove them to get ATE to work. I could add their direct network printers no problem.
Well the good news is that you are almost certainly in the lead for the longest unsolved bug competition. The bad news is that you can’t officially take the prize until the bug is fixed, and we don’t seem to be any closer to that.
The other good news is that no one else has reported it.
I’m out in Palm Springs for a couple of days; maybe I’ll get some kind of inspiration staring at the palm trees swaying in the breeze…