diff PrivateQueue.h @ 19:1ed562d601d9

Newly created project repository -- commit sub-states
author Me@portablequad
date Tue, 07 Feb 2012 12:51:29 -0800
parents 174a7c2ca340
children b5ae7fbb1f01 c5d2f2a94133
line diff
     1.1 --- a/PrivateQueue.h	Thu Nov 04 17:50:29 2010 -0700
     1.2 +++ b/PrivateQueue.h	Tue Feb 07 12:51:29 2012 -0800
     1.3 @@ -1,37 +1,37 @@
     1.4 -/*
     1.5 - *  Copyright 2009 OpenSourceStewardshipFoundation.org
     1.6 - *  Licensed under GNU General Public License version 2
     1.7 - *
     1.8 - * Author: seanhalle@yahoo.com
     1.9 - */
    1.10 -
    1.11 -#ifndef _PRIVATE_QUEUE_H
    1.12 -#define	_PRIVATE_QUEUE_H
    1.13 -
    1.14 -#include <pthread.h>
    1.15 -
    1.16 -#define TRUE     1
    1.17 -#define FALSE    0
    1.18 -
    1.19 -#define LOCKED   1
    1.20 -#define UNLOCKED 0
    1.21 -
    1.22 -
    1.23 -/* It is the data that is shared so only need one mutex. */
    1.24 -typedef struct
    1.25 - { void      **insertPos;
    1.26 -   void      **extractPos;
    1.27 -   void      **startOfData;  //data is pointers
    1.28 -   void      **endOfData;    //set when alloc data
    1.29 - }
    1.30 -PrivQueueStruc;
    1.31 -
    1.32 -
    1.33 -PrivQueueStruc*  makePrivQ ( );
    1.34 -void*            readPrivQ ( PrivQueueStruc *Q );
    1.35 -void             writePrivQ( void *in, PrivQueueStruc *Q );
    1.36 -int              writeIfSpacePrivQ( void * in, PrivQueueStruc* Q ); //return
    1.37 -                    // false when full
    1.38 -
    1.39 -#endif	/* _PRIVATE_QUEUE_H */
    1.40 -
    1.41 +/*
    1.42 + *  Copyright 2009 OpenSourceStewardshipFoundation.org
    1.43 + *  Licensed under GNU General Public License version 2
    1.44 + *
    1.45 + * Author: seanhalle@yahoo.com
    1.46 + */
    1.47 +
    1.48 +#ifndef _PRIVATE_QUEUE_H
    1.49 +#define	_PRIVATE_QUEUE_H
    1.50 +
    1.51 +#include <pthread.h>
    1.52 +
    1.53 +#define TRUE     1
    1.54 +#define FALSE    0
    1.55 +
    1.56 +#define LOCKED   1
    1.57 +#define UNLOCKED 0
    1.58 +
    1.59 +
    1.60 +/* It is the data that is shared so only need one mutex. */
    1.61 +typedef struct
    1.62 + { void      **insertPos;
    1.63 +   void      **extractPos;
    1.64 +   void      **startOfData;  //data is pointers
    1.65 +   void      **endOfData;    //set when alloc data
    1.66 + }
    1.67 +PrivQueueStruc;
    1.68 +
    1.69 +
    1.70 +PrivQueueStruc*  makePrivQ ( );
    1.71 +void*            readPrivQ ( PrivQueueStruc *Q );
    1.72 +void             writePrivQ( void *in, PrivQueueStruc *Q );
    1.73 +int              writeIfSpacePrivQ( void * in, PrivQueueStruc* Q ); //return
    1.74 +                    // false when full
    1.75 +
    1.76 +#endif	/* _PRIVATE_QUEUE_H */
    1.77 +