mirror of
https://github.com/Cockatrice/Cockatrice.git
synced 2026-06-10 08:14:47 -07:00
changed a lot of thread locking code in the server, rooms are working with ISL now
This commit is contained in:
parent
572e4eaafa
commit
c23af44749
16 changed files with 449 additions and 221 deletions
|
|
@ -14,10 +14,11 @@ class Server_ProtocolHandler;
|
|||
class ServerLogger : public QObject {
|
||||
Q_OBJECT
|
||||
public:
|
||||
ServerLogger(const QString &logFileName, QObject *parent = 0);
|
||||
ServerLogger(QObject *parent = 0);
|
||||
~ServerLogger();
|
||||
static void hupSignalHandler(int unused);
|
||||
public slots:
|
||||
void startLog(const QString &logFileName);
|
||||
void logMessage(QString message, void *caller = 0);
|
||||
private slots:
|
||||
void handleSigHup();
|
||||
|
|
@ -33,19 +34,4 @@ private:
|
|||
QMutex bufferMutex;
|
||||
};
|
||||
|
||||
class ServerLoggerThread : public QThread {
|
||||
Q_OBJECT
|
||||
private:
|
||||
QString fileName;
|
||||
ServerLogger *logger;
|
||||
QWaitCondition initWaitCondition;
|
||||
protected:
|
||||
void run();
|
||||
public:
|
||||
ServerLoggerThread(const QString &_fileName, QObject *parent = 0);
|
||||
~ServerLoggerThread();
|
||||
ServerLogger *getLogger() const { return logger; }
|
||||
void waitForInit();
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue