Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
688a6bec70
  1. 18
      iguana/main.c

18
iguana/main.c

@ -422,18 +422,24 @@ void mainloop(struct supernet_info *myinfo)
counter++; counter++;
coin = 0; coin = 0;
depth = 0; depth = 0;
HASH_ITER(hh,myinfo->allcoins,coin,tmp) if ( 0 )
{ {
portable_mutex_lock(&coin->allcoins_mutex); HASH_ITER(hh,myinfo->allcoins,coin,tmp)
stack[depth++] = &coin->allcoins_mutex; {
portable_mutex_lock(&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 ( depth > 0 ) if ( 0 )
{ {
for (i=depth-1; i>=0; i--) if ( depth > 0 )
portable_mutex_unlock(stack[i]); {
for (i=depth-1; i>=0; i--)
portable_mutex_unlock(stack[i]);
}
} }
lastmilli = OS_milliseconds(); lastmilli = OS_milliseconds();
} }

Loading…
Cancel
Save