diff --git a/veejay-current/veejay-server/libOSC/NetworkUDP.h b/veejay-current/veejay-server/libOSC/NetworkUDP.h index 7f693250..7cf09e43 100644 --- a/veejay-current/veejay-server/libOSC/NetworkUDP.h +++ b/veejay-current/veejay-server/libOSC/NetworkUDP.h @@ -2,6 +2,6 @@ struct NetworkReturnAddressStruct { struct sockaddr_in cl_addr; - int clilen; + unsigned int clilen; int sockfd; }; diff --git a/veejay-current/veejay-server/libOSC/OSC-common.c b/veejay-current/veejay-server/libOSC/OSC-common.c index c5808a39..5aa5be2d 100644 --- a/veejay-current/veejay-server/libOSC/OSC-common.c +++ b/veejay-current/veejay-server/libOSC/OSC-common.c @@ -51,6 +51,7 @@ The OpenSound Control WWW page is #include #include +#include #include #include #include diff --git a/veejay-current/veejay-server/libOSC/OSC-priority-queue.c b/veejay-current/veejay-server/libOSC/OSC-priority-queue.c index 5c29b694..bcb01637 100644 --- a/veejay-current/veejay-server/libOSC/OSC-priority-queue.c +++ b/veejay-current/veejay-server/libOSC/OSC-priority-queue.c @@ -40,18 +40,8 @@ The OpenSound Control WWW page is #include #include #include -#include -#define PRINT_PRIORITY_QUEUE - -#ifdef DEBUG_OSC_PRIORITY_QUEUE -#define PRINT_PRIORITY_QUEUE -#endif - -#if defined(PRINT_PRIORITY_QUEUE) || defined(DEBUG_OSC_PRIORITY_QUEUE) - #include -void OSCQueuePrint(OSCQueue q); -#endif +#include #define CAPACITY 1000 @@ -73,9 +63,6 @@ OSCQueue OSCNewQueue(int maxItems, void *(*InitTimeMalloc)(int numBytes)) { result->n = 0; -#ifdef DEBUG_OSC_PRIORITY_QUEUE - OSCQueuePrint(result); -#endif return result; } @@ -84,10 +71,6 @@ int OSCQueueInsert(OSCQueue q, OSCSchedulableObject new) { q->list[q->n] = new; ++(q->n); -#ifdef DEBUG_OSC_PRIORITY_QUEUE - printf("OSCQueueInsert: just inserted %p\n", new); - OSCQueuePrint(q); -#endif return TRUE; } @@ -102,10 +85,6 @@ OSCTimeTag OSCQueueEarliestTimeTag(OSCQueue q) { } } -#ifdef DEBUG_OSC_PRIORITY_QUEUE - printf("OSCQueueEarliestTimeTag: about to return %llx\n", smallest); - OSCQueuePrint(q); -#endif return smallest; } @@ -128,11 +107,6 @@ OSCSchedulableObject OSCQueueRemoveEarliest(OSCQueue q) { return NULL; } -#ifdef DEBUG_OSC_PRIORITY_QUEUE - printf("OSCQueueRemoveEarliest: begin\n"); - OSCQueuePrint(q); -#endif - smallestIndex = 0; for (i = 1; i < q->n; ++i) { if (OSCTT_Compare(q->list[smallestIndex]->timetag, q->list[i]->timetag) > 0) { @@ -144,28 +118,9 @@ OSCSchedulableObject OSCQueueRemoveEarliest(OSCQueue q) { RemoveElement(smallestIndex, q); -#ifdef DEBUG_OSC_PRIORITY_QUEUE - printf("OSCQueueRemoveEarliest: done\n"); - OSCQueuePrint(q); -#endif return result; } -#ifdef PRINT_PRIORITY_QUEUE - -void OSCQueuePrint(OSCQueue q) { - int i; - printf("OSC Priority queue at %p has %d elements:\n", q, q->n); - - for (i = 0; i < q->n; ++i) { - printf(" list[%2d] is %p, timetag = %llx\n", i, q->list[i], q->list[i]->timetag); - } - printf("\n\n"); -} - -#endif - - void OSCQueueScanStart(OSCQueue q) { q->scanIndex = 0; } diff --git a/veejay-current/veejay-server/libOSC/OSC-receive.c b/veejay-current/veejay-server/libOSC/OSC-receive.c index ada37657..71ebd0a5 100644 --- a/veejay-current/veejay-server/libOSC/OSC-receive.c +++ b/veejay-current/veejay-server/libOSC/OSC-receive.c @@ -35,15 +35,15 @@ The OpenSound Control WWW page is Adapted from OSC-addressability.c (and seriously cleaned up!) */ - #include - #include - #include - #include - #include - #include - #include - #include - #include +#include +#include +#include +#include +#include +#include +#include +#include +#include #include #include #include @@ -821,7 +821,7 @@ Boolean OSCScheduleInternalMessages(OSCTimeTag when, int numMessages, } Boolean NetworkPacketWaiting(OSCPacketBuffer packet) { - int n; + NetworkReturnAddressPtr na = OSCPacketBufferGetClientAddr(packet); // if( use_mcast_ ) diff --git a/veejay-current/veejay-server/libOSC/OSC-string-help.c b/veejay-current/veejay-server/libOSC/OSC-string-help.c index f42086e8..f59c3cb4 100644 --- a/veejay-current/veejay-server/libOSC/OSC-string-help.c +++ b/veejay-current/veejay-server/libOSC/OSC-string-help.c @@ -87,7 +87,7 @@ int OSCPaddedStrlen(const char *s) { } char *OSCPaddedStrcpy(char *target, const char *source) { - while ( (*target++) = (*source++)) { + while ( *target++ = *source++ ) { /* do nothing */ } diff --git a/veejay-current/veejay-server/libOSC/OSC-struct.h b/veejay-current/veejay-server/libOSC/OSC-struct.h index 6e17b15d..52b2810d 100644 --- a/veejay-current/veejay-server/libOSC/OSC-struct.h +++ b/veejay-current/veejay-server/libOSC/OSC-struct.h @@ -17,7 +17,7 @@ typedef int int4; /* 4 byte int */ typedef struct NetworkReturnAddressStruct_t { struct sockaddr_in cl_addr; /* client information */ struct sockaddr_in my_addr; /* us */ - int clilen; + unsigned int clilen; int sockfd; fd_set readfds; struct timeval tv;