On 8.2.2010 20:11, Roy Lambert wrote: > That's a bit difficult since the coderunning in the thread is in an > external module loaded by ElevateDB at run time and depending on how > much I comment out I get different errors. eg with the following ... > I get an AV > > Run just one thread and everything's fine. Run two and kerpow.
Most of the time access violations are caused by uninitialised (either object has not yet been initialised or has already been freed) or inaccessible (outside of scope) references to objects. Perhaps you (or a component you're using?) are attempting to do something that requires a criticalsection or something. Just guessing here. Personally, I've never had a problem of using TMimeMess within threads. Or ... to be more precise, I've never had a problem that was caused by the TMimeMess. I grant that debugging threaded applications can often be a real pain; the cause-effect -relationship can easily be far from clear :( From the example you posted, it is a bit unclear what would be the cause for the access violation (because apparently you're only attempting to create and free the asource; you're not even doing anything with it). Does the function return without problems if you exit just after the "Reversing := ..."-line (ie. before even attempting to create the asource) ? -- Markku Uttula ------------------------------------------------------------------------------ The Planet: dedicated and managed hosting, cloud storage, colocation Stay online with enterprise data centers and the best network in the business Choose flexible plans and management services without long-term contracts Personal 24x7 support from experience hosting pros just a phone call away. http://p.sf.net/sfu/theplanet-com _______________________________________________ synalist-public mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/synalist-public
