Bug Report (AHK.dll) Topic is solved

Post AHK_H specific scripts & libraries and discuss the usage and development of HotKeyIt's fork/branch
User avatar
Masonjar13
Posts: 1555
Joined: 20 Jul 2014, 10:16
Location: Не Россия
Contact:

Bug Report (AHK.dll)

15 Mar 2018, 13:02

Updating ScriptUp with some new features, so I made a sample script to test them out.

Code: Select all

#singleInstance force
#persistent
#include *i <Lib_1>

loop
    msgbox Test
I downloaded the newest version (1.1.28.00-H004), and I'm using the 64-bit version. Using ahkTerminate on the thread will crash the process. ahkReload works fine, as does ahkPause or anything else as far as I can tell. Trying to terminate while paused doesn't make a difference. The previous version I was using (1.1.26.01-H001) doesn't cause a crash, same script.
OS: Windows 10 Pro | Editor: Notepad++
My Personal Function Library | Old Build - New Build
HotKeyIt
Posts: 2364
Joined: 29 Sep 2013, 18:35
Contact:

Re: Bug Report (AHK.dll)

18 Mar 2018, 19:30

I can't reproduce it on Win 10 64-bit, in your script you are not using ahk.dll, can you provide a full example showing the problem?
User avatar
Masonjar13
Posts: 1555
Joined: 20 Jul 2014, 10:16
Location: Не Россия
Contact:

Re: Bug Report (AHK.dll)

18 Mar 2018, 21:43

Right, it's a script that's being ran with ahk.dll. Specifically, I'm using ScriptUp, which you can download and add the above script to. That's exactly my use case. However, I don't use Win 10, so it may or may not be different.
OS: Windows 10 Pro | Editor: Notepad++
My Personal Function Library | Old Build - New Build
HotKeyIt
Posts: 2364
Joined: 29 Sep 2013, 18:35
Contact:

Re: Bug Report (AHK.dll)

19 Mar 2018, 04:57

What OS do you use?
Can you write down the steps you do to cause the crash?
User avatar
Masonjar13
Posts: 1555
Joined: 20 Jul 2014, 10:16
Location: Не Россия
Contact:

Re: Bug Report (AHK.dll)

19 Mar 2018, 11:27

Windows 7
1. Open ScriptUp with _L v1.1.27.7 (updated to 1.1.28.0, still crashes) (64-bit)
2. In the ScriptUp GUI, press "Settings" > "Set DLL: Std" and select v1.1.28.00-H004 of ahk.dll (64-bit)
3. Save the script above (any infinite loop seems to work) and add it to ScriptUp by dragging it to the GUI. Set it to use the Std DLL.
4. Try closing ScriptUp (from tray menu).

This will 100% of the time crash for me. If I remove that particular script, perfectly fine. This is the only time ahkTerminate is called, so I can only presume this is the problem (I can't check exactly where it crashes).
OS: Windows 10 Pro | Editor: Notepad++
My Personal Function Library | Old Build - New Build
HotKeyIt
Posts: 2364
Joined: 29 Sep 2013, 18:35
Contact:

Re: Bug Report (AHK.dll)  Topic is solved

25 Mar 2018, 10:20

Tried but it did not add the script to the list, when starting again I got this error:
There were errors while trying to run scripts:

DLL path not specified: Std
I believe the bug has been fixed in the last release, can you test it please: https://github.com/HotKeyIt/ahkdll-v1-r ... master.zip
User avatar
Masonjar13
Posts: 1555
Joined: 20 Jul 2014, 10:16
Location: Не Россия
Contact:

Re: Bug Report (AHK.dll)

25 Mar 2018, 16:25

Hm, that's not an issue I've ever had (unless I purposely caused it). If you added the DLL then moved it, the path would be incorrect and cause that error. You can check %appdata%\..\Local\ScriptUp for the ini config file. Should be key "Std" under section "dlltypes." If the script didn't have privilege to write to there, that would also be a problem (though any scripts added would also be forgotten).

I've tested H008 and it seems to work perfectly fine! Fixed :thumbup:
OS: Windows 10 Pro | Editor: Notepad++
My Personal Function Library | Old Build - New Build
User avatar
Drugwash
Posts: 850
Joined: 29 May 2014, 21:07
Location: Ploieşti, Romania
Contact:

Re: Bug Report (AHK.dll)

15 Apr 2018, 01:12

@ Masonjar13: Around the same time, I tested your script and got the same error as HotkeyIt above. Can't remember exactly how I fixed it but I think both paths to standard DLL and mini DLL must be specified at first run, otherwise only specifying one of them will not hold, and scripts will not be added to the list.
You may wanna double-check that part of the script and maybe notify the user about the requirements. ;)
Part of my AHK work can be found here.
User avatar
Masonjar13
Posts: 1555
Joined: 20 Jul 2014, 10:16
Location: Не Россия
Contact:

Re: Bug Report (AHK.dll)

15 Apr 2018, 07:03

Drugwash wrote:You may wanna double-check that part of the script and maybe notify the user about the requirements. ;)
Thanks for the heads up. I checked the code again, and that isn't the case. I even manually removed the path to the mini DLL and restarted it. As expected, all scripts using the standard DLL were running, but the mini ones were not. When a DLL path is changed, it changes it both in the object and the ini file, so it can't be missed.

I see no errors in the code, but if you'd like to test it further, please let me know if you find anything :thumbup:

Thought: If it's W10, maybe it's a permissions issue? I could add an admin check.
OS: Windows 10 Pro | Editor: Notepad++
My Personal Function Library | Old Build - New Build
User avatar
Drugwash
Posts: 850
Joined: 29 May 2014, 21:07
Location: Ploieşti, Romania
Contact:

Re: Bug Report (AHK.dll)

15 Apr 2018, 07:55

I tested in XP where I am definitely admin, so that's not the issue.
There must be a niche situation where it's not behaving quite correctly, since it's at least two of us (HotkeyIt and myself) who experienced this issue.
Unfortunately I can't remember the exact steps to reproduce it. Maybe if you start from scratch with no ini file, try to add a script and run it, restart ScriptUp script when failed, try to set only Std DLL path, try to add and run a script again, restart ScriptUp, then change both DLL paths.
I couldn't even get it to add a script to the list, at first, before setting the DLL path, if I recall correctly.
Anyway, this issue is not related to AHK_H itself so we're not quite in the right place to discuss it. Just wanted to let you know HotkeyIt's report does have a plausible ground.
Part of my AHK work can be found here.

Return to “AutoHotkey_H”

Who is online

Users browsing this forum: No registered users and 29 guests