UPDATE: I reviewed the thread that was returning and tracked it down to a .dll that is being built by us too. Doublechecking this showed that there was a _USRDLL and WINDOWS compile definition missing. I added these and this has working as intended.