Different behavior in Debug and Release configuration in threaded code is a good sign of race condition, see http://en.wikipedia.org/wiki/Race_condition
]. I prefer more descriptive form of such phenomena: "incorrect dependency on the order of execution". Please checkup the logic of your threads communications and use of shared resources.
Less likely reason is automatic filling of non-assigned members in C++ objects which can be more deterministic in Debug configuration.