Annotation of truecrypt/platform/syncevent.h, revision 1.1

1.1     ! root        1: /*
        !             2:  Copyright (c) 2008 TrueCrypt Foundation. All rights reserved.
        !             3: 
        !             4:  Governed by the TrueCrypt License 2.5 the full text of which is contained
        !             5:  in the file License.txt included in TrueCrypt binary and source code
        !             6:  distribution packages.
        !             7: */
        !             8: 
        !             9: #ifndef TC_HEADER_Platform_SyncEvent
        !            10: #define TC_HEADER_Platform_SyncEvent
        !            11: 
        !            12: #ifdef TC_WINDOWS
        !            13: #      include "System.h"
        !            14: #else
        !            15: #      include <pthread.h>
        !            16: #endif
        !            17: #include "PlatformBase.h"
        !            18: #include "Mutex.h"
        !            19: 
        !            20: namespace TrueCrypt
        !            21: {
        !            22:        class SyncEvent
        !            23:        {
        !            24:        public:
        !            25:                SyncEvent ();
        !            26:                ~SyncEvent ();
        !            27: 
        !            28:                void Signal ();
        !            29:                void Wait ();
        !            30: 
        !            31:        protected:
        !            32:                bool Initialized;
        !            33: #ifdef TC_WINDOWS
        !            34:                HANDLE SystemSyncEvent;
        !            35: #else
        !            36:                volatile bool Signaled;
        !            37:                pthread_cond_t SystemSyncEvent;
        !            38:                Mutex EventMutex;
        !            39: #endif
        !            40: 
        !            41:        private:
        !            42:                SyncEvent (const SyncEvent &);
        !            43:                SyncEvent &operator= (const SyncEvent &);
        !            44:        };
        !            45: }
        !            46: 
        !            47: #endif // TC_HEADER_Platform_SyncEvent

unix.superglobalmegacorp.com

This archive runs on limited infrastructure. Preserving old code on modern bandwidth. Automated agents are requested to crawl responsibly.