Author Topic: Access Violation using 1.7.3 or 1.7.4 in dynamically loded Windows DLL  (Read 58533 times)

Rich Hornay

  • Newbie
  • *
  • Posts: 4
    • View Profile
I’m seeing an Access Violation on unload in crtdll.c on line 531 using 1.7.3 or 1.7.4 (v90 or v100 toolsets) in a dynamically loaded/unloaded Windows DLL.

First-chance exception at 0x000007fefb8bc413 (jtindll.dll) in JTTest.exe: 0xC0000005: Access violation writing location 0x0000000000000410.

From crtdll.c line 531 debugging:
_pRawDllMain = 0x000007fefb8be8d0 `anonymous namespace'::run_tls_callback(void * ptr64,unsigned long,void * ptr64)


The exception appears to be handled, but I am concerned and generally don’t care for anomalous behaviors.  I can provide the test if you wish, but it is pretty simple.  The dll exports start() and stop().  start() creates a thread and stop() joins it.  The exe just loads the dll, calls start then stop and unloads the dll.  This is just native code, no managed nonsense.
Can you confirm/explain this? 

Anthony Williams

  • Administrator
  • Full Member
  • *****
  • Posts: 103
    • View Profile
    • just::thread C++ Thread Library
Re: Access Violation using 1.7.3 or 1.7.4 in dynamically loded Windows DLL
« Reply #1 on: August 20, 2012, 10:53:23 AM »
That's a known issue with those releases. I've just updated everyone to V1.7.4.1 (Windows only release), which should fix this problem.

Please download the new version and try again. If there is still a problem, then I'll investigate further.

Rich Hornay

  • Newbie
  • *
  • Posts: 4
    • View Profile
Re: Access Violation using 1.7.3 or 1.7.4 in dynamically loded Windows DLL
« Reply #2 on: August 20, 2012, 07:07:13 PM »
Nice!

I hadn't seen anything about a 1.7.4.1 update.  I just updated and ran the test...fixed!
Thank you sir.