RTC Forums
November 23, 2024, 08:54:45 PM *
Welcome, Guest. Please login or register.

Login with username, password and session length
 
   Home   Help Login Register  
Pages: [1]
  Print  
Author Topic: TRTLCriticalSection vs TRtcCritSec  (Read 5017 times)
Ecole7
RTC Expired
*
Posts: 23


« on: May 15, 2017, 06:18:00 PM »

Hello,
I want to know what is the difference between the TRTLCriticalSection in standard library on Delphi, and TRtcCritSec in your library.
I use TRTLCriticalSection in my application server.
Should TRtcCritSec be used?
Thank you in advance for your answer.
Vincent
Logged
D.Tkalcec (RTC)
Administrator
*****
Posts: 1881


« Reply #1 on: May 15, 2017, 06:58:55 PM »

Debugging. That's the only difference. Fiding a deadlock without having your own implementation of the critical section class can be challenging.

If you take a closer look at the "Acquire" method implemented on the "TRtcCritSec" class, which is used only if the RTC_WIN32_CS_DEBUG compiler define is declared (and should NOT be used in production), you will see what I mean.

Best Regards,
Danijel Tkalcec
Logged
Ecole7
RTC Expired
*
Posts: 23


« Reply #2 on: May 16, 2017, 08:30:42 AM »

Thank you for your quick response.
I have a problem with my application which happens very rarely (once every two months ...).
I guess it could come from my own log file system. I now use yours which is much better written.
I have another question for you also related to this problem.
Logged
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!
Page created in 0.024 seconds with 17 queries.