|
|
@ -680,6 +680,8 @@ cJSON *LP_pricearray(char *base,char *rel,uint32_t firsttime,uint32_t lasttime,i |
|
|
|
numbids = numasks = 0; |
|
|
|
bidsum = asksum = askemit = bidemit = highbid = lowbid = highask = lowask = 0.; |
|
|
|
if ( (bidfp= fopen(bidfname,"rb")) != 0 && (askfp= fopen(askfname,"rb")) != 0 ) |
|
|
|
{ |
|
|
|
while ( bidfp != 0 || askfp != 0 ) |
|
|
|
{ |
|
|
|
bidi = aski = 0; |
|
|
|
bidemit = askemit = 0.; |
|
|
@ -756,6 +758,7 @@ cJSON *LP_pricearray(char *base,char *rel,uint32_t firsttime,uint32_t lasttime,i |
|
|
|
lastbidi = bidi; |
|
|
|
if ( aski != 0 ) |
|
|
|
lastaski = aski; |
|
|
|
} |
|
|
|
} else printf("couldnt open either %s %p or %s %p\n",bidfname,bidfp,askfname,askfp); |
|
|
|
if ( bidfp != 0 ) |
|
|
|
fclose(bidfp); |
|
|
|