AndersMalmgren / FreePIE

Programmable Input Emulator
647 stars 144 forks source link

Crash if started script, stopped, introduced an error, started. #179

Closed wadim-al closed 5 years ago

wadim-al commented 5 years ago

Problem: if script was run, stopped, edited so error was introduced and started the app crashes.

OS: Windows 10 x64 FreePIE: 1.11.724.0

Steps.

  1. Open orbiter.py
  2. Start script
  3. Stop script
  4. Uncomment lines 34 and 35 to introduce variable not defined error
  5. Repeat the steps until crashed.

orbiter - Copy.py.txt FreePIE.exe.3692.dmp.txt

AndersMalmgren commented 5 years ago

FreePIE.Core.Plugins.zip

Please try this version, I did a small fix to the hydra plugin. Make sure that the dll is not blocked since its downloaded from internet

wadim-al commented 5 years ago

After replacing the new .dll I've started getting errors. Errors: an item with the same key has already been added object reference not set to an instance of a object Reinstalling the FreePIE did not help. Don't know how to recover. Registry cleaning? regsvr dll unregister? Happens even with script using only keyboard commands. FreePIE_2019-08-26_13-10-41

AndersMalmgren commented 5 years ago

Strange all I changed from the released version is a small thing in how we handel errors in hydra

wadim-al commented 5 years ago

Will try to remove all references of that dll from the registry, plus all reg keys for FreePIE which I will find.

wadim-al commented 5 years ago

I was able to cleanly reinstall. Still after adding a new dll I'm getting the same errors. Was able to return back to original dll.

AndersMalmgren commented 5 years ago

And you have made sure its not blocked?

AndersMalmgren commented 5 years ago

image

wadim-al commented 5 years ago

There is no Unblock checkbox for this file on my Win10. You can try this dll yourself and use any script like 'keyboard.setPressed(Key.A, Key.B)' to see if you will have those errors. Hydra not needed.

AndersMalmgren commented 5 years ago

It seems .net is a bit funny. Could it be you hava renamed old file to dllold, dllbak os similar

image

AndersMalmgren commented 5 years ago

I'll fix that for next version of freepie

            var dlls = fileSystem
                .GetFiles(path, "*.dll")
                .Where(dll => dll.EndsWith("dll", StringComparison.InvariantCultureIgnoreCase))
                .ToList();
wadim-al commented 5 years ago

I confirm, that I've renamed the dll to dll1

wadim-al commented 5 years ago

Tested the new dll, without old. Now it is not crashing. Fixed. Thanks!