Mercurial > cgi-bin > hgwebdir.cgi > VMS > C_Libraries > Queue_impl
changeset 17:1e93e5dbeda1 VMS__malloc_brch
Build process fix
| author | Merten Sach <msach@mailbox.tu-berlin.de> |
|---|---|
| date | Wed, 22 Jun 2011 16:55:10 +0200 |
| parents | 8fd77f9430f0 |
| children | 7c9e00ff1bf4 |
| files | BlockingQueue.c PrivateQueue.c |
| diffstat | 2 files changed, 5 insertions(+), 4 deletions(-) [+] |
line diff
1.1 --- a/BlockingQueue.c Sun Nov 14 11:14:51 2010 -0800 1.2 +++ b/BlockingQueue.c Wed Jun 22 16:55:10 2011 +0200 1.3 @@ -13,6 +13,7 @@ 1.4 #include <sched.h> 1.5 1.6 #include "BlockingQueue.h" 1.7 +#include "../vmalloc.h" 1.8 1.9 #define INC(x) (++x == 1024) ? (x) = 0 : (x) 1.10
2.1 --- a/PrivateQueue.c Sun Nov 14 11:14:51 2010 -0800 2.2 +++ b/PrivateQueue.c Wed Jun 22 16:55:10 2011 +0200 2.3 @@ -12,6 +12,7 @@ 2.4 #include <stdlib.h> 2.5 2.6 #include "PrivateQueue.h" 2.7 +#include "../vmalloc.h" 2.8 2.9 2.10 2.11 @@ -23,10 +24,9 @@ 2.12 2.13 PrivQueueStruc* makeVMSPrivQ() 2.14 { 2.15 - PrivQueueStruc* retQ; 2.16 - retQ = (PrivQueueStruc *) VMS__malloc( sizeof( PrivQueueStruc ) ); 2.17 - 2.18 - retQ->startOfData = VMS__malloc( 1024 * sizeof(void *) ); 2.19 + PrivQueueStruc *retQ; 2.20 + retQ = VMS__malloc( sizeof( PrivQueueStruc ) ); 2.21 + retQ->startOfData = (void*)VMS__malloc( 1024 * sizeof(void *) ); 2.22 memset( retQ->startOfData, 0, 1024 ); 2.23 2.24 retQ->extractPos = &(retQ->startOfData[0]); //side by side == empty
