Is FindFirst, FindNext & Thread FindClose sicuro in delphi? Se no, cosa dovrebbe essere usato lì?È FindFirst, FindNext & FindClose Thread safe in delphi
6
A
risposta
13
FindFirst, FindNext & FindClose utilizza le chiamate API e sono thread-safe. Ogni thread deve utilizzare il proprio handle API per l'accesso ai file.
5
Se non si utilizza una variabile TSearchRec condivisa, le routine sono thread-safe.
+0
TSearchRec è definito nella parte "Esegui" della discussione –
Problemi correlati
- 1. Coda priorità thread-safe per Delphi?
- 2. ricerca file delphi multithreading
- 3. NSTimer è thread-safe?
- 4. Stream.Write è thread-safe?
- 5. HttpContext.Current.Cache è thread-safe?
- 6. PutStrLn è thread-safe?
- 7. È `asprintf` thread-safe?
- 8. SQLite.Net è thread-safe?
- 9. PHP è thread-safe?
- 10. Isertools è thread-safe?
- 11. è java.util.UUID thread safe?
- 12. NSIndexPath è thread-safe?
- 13. PrintWriter è thread-safe?
- 14. è unmodifiableList thread safe?
- 15. È thread safe RNGCryptoServiceProvider.GetBytes?
- 16. È un codice thread-safe? Come posso renderlo thread-safe?
- 17. In Delphi, il thread OutputDebugString è sicuro?
- 18. FindFirst dovrebbe restituire i file trovati in ordine alfabetico?
- 19. Java MulticastSocket è thread-safe?
- 20. Azure CloudTable è thread-safe?
- 21. python dictionary è thread-safe?
- 22. Il filtro è thread-safe
- 23. Questo è thread-safe giusto?
- 24. Azure TopicClient è thread-safe?
- 25. È std :: regex thread safe?
- 26. Copia di un sacco di file in Delphi
- 27. Questo deque thread-safe è in python?
- 28. DocumentBuilderFactory è thread-safe in Java 5+?
- 29. È BlockingQueue completamente thread-safe in Java
- 30. è @Singleton in Dagger 2 thread safe?
Sì, è giusto, ma utilizzare le chiamate API e tutte le variabili locali vengono memorizzate nello stack ad eccezione di TSearchRec. Quindi, se non condividi TSearchRec tra i thread, è sicuro. –