remove(spCacheFilename);
#endif
//if cache is still existing, we need to write back the rest of the cache
- while (cache)
+ if (cache)
{
- cachePointer next = cache->next;
- write_to_cache(cache->game,cache->system,cache->prid,cache->score,0);
- free(cache);
- cache = next;
+ SDL_RWops *file = SDL_RWFromFile(spCacheFilename, "ab");
+ while (cache)
+ {
+ cachePointer next = cache->next;
+ SDL_RWwrite(file,cache->game,256,1);
+ SDL_RWwrite(file,cache->system,256,1);
+ SDL_RWwrite(file,cache->prid,256,1);
+ SDL_RWwrite(file,&(cache->score),sizeof(int),1);
+ free(cache);
+ cache = next;
+ }
+ SDL_RWclose(file);
}
}
DEPENDS = "virtual/libsdl libsdl-net pandora-libpnd"
RDEPENDS = "libsdl-net pandora-libpnd"
-PR = "r1"
+PR = "r2"
PR_append = "+gitr${SRCPV}"
SRC_URI = " \
file://sparrowDefines.h \
"
-SRCREV = "ef70184115cf3da4e2f611dc0f86c0d7fe991235"
+SRCREV = "73642236bbce54852e2a40c4b373b96ee6055691"
S = "${WORKDIR}/git"