If two or more threads call a standard Delphi/Pascal procedure (not a method of an object), is this threadsafe ? There is no instance data, just local variables in the procedure.
My guess is that the local storage being used by one thread could be corrupted by the other thread.
Local storage is maintained on the stack, which is unique to each thread. If no global data is being manipulated by the routine, it is safe.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With