Use int instead of bool ... libraries sometimes redefine bool in headers.

This commit is contained in:
Michael Jumper 2013-06-28 15:52:17 -07:00
parent 976e3af24b
commit 90697e35ba
2 changed files with 3 additions and 4 deletions

View File

@ -39,7 +39,6 @@
#define _GUAC_SOCKET_H
#include <pthread.h>
#include <stdbool.h>
#include <stdint.h>
#include <unistd.h>
@ -193,7 +192,7 @@ struct guac_socket {
* Whether instructions should be guaranteed atomic across threads using
* locks. By default, thread safety is disabled on sockets.
*/
bool __threadsafe_instructions;
int __threadsafe_instructions;
/**
* Lock which is acquired when an instruction is being written, and

View File

@ -157,7 +157,7 @@ guac_socket* guac_socket_alloc() {
/* Default to unsafe threading */
socket->__threadsafe_instructions = false;
socket->__threadsafe_instructions = 0;
pthread_mutex_init(&(socket->__instruction_write_lock), NULL);
/* No handlers yet */
@ -171,7 +171,7 @@ guac_socket* guac_socket_alloc() {
}
void guac_socket_require_threadsafe(guac_socket* socket) {
socket->__threadsafe_instructions = true;
socket->__threadsafe_instructions = 1;
}
void guac_socket_instruction_begin(guac_socket* socket) {