mattifestation/PowerSploit — pull request #13 by clymb3r (2013-09-04 03:12:02+00:00)
Title: Call to DllMain when unloading reflective DLL

Prior to this fix, DllMain with the ProessDetach flag was not called
when unloading the reflectively loaded DLL. This was causing very weird
crashes in the Invoke-NinjaCopy script which is built on this script.
This should fix the crash.