|
@ -422,19 +422,25 @@ void mainloop(struct supernet_info *myinfo) |
|
|
counter++; |
|
|
counter++; |
|
|
coin = 0; |
|
|
coin = 0; |
|
|
depth = 0; |
|
|
depth = 0; |
|
|
|
|
|
if ( 0 ) |
|
|
|
|
|
{ |
|
|
HASH_ITER(hh,myinfo->allcoins,coin,tmp) |
|
|
HASH_ITER(hh,myinfo->allcoins,coin,tmp) |
|
|
{ |
|
|
{ |
|
|
portable_mutex_lock(&coin->allcoins_mutex); |
|
|
portable_mutex_lock(&coin->allcoins_mutex); |
|
|
stack[depth++] = &coin->allcoins_mutex; |
|
|
stack[depth++] = &coin->allcoins_mutex; |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
//printf("check jsonQ\n");
|
|
|
//printf("check jsonQ\n");
|
|
|
while ( iguana_jsonQ() != 0 ) |
|
|
while ( iguana_jsonQ() != 0 ) |
|
|
; |
|
|
; |
|
|
|
|
|
if ( 0 ) |
|
|
|
|
|
{ |
|
|
if ( depth > 0 ) |
|
|
if ( depth > 0 ) |
|
|
{ |
|
|
{ |
|
|
for (i=depth-1; i>=0; i--) |
|
|
for (i=depth-1; i>=0; i--) |
|
|
portable_mutex_unlock(stack[i]); |
|
|
portable_mutex_unlock(stack[i]); |
|
|
} |
|
|
} |
|
|
|
|
|
} |
|
|
lastmilli = OS_milliseconds(); |
|
|
lastmilli = OS_milliseconds(); |
|
|
} |
|
|
} |
|
|
usleep(30000); |
|
|
usleep(30000); |
|
|