summaryrefslogtreecommitdiff
path: root/apps
diff options
context:
space:
mode:
Diffstat (limited to 'apps')
-rw-r--r--apps/database.c21
1 files changed, 11 insertions, 10 deletions
diff --git a/apps/database.c b/apps/database.c
index 14229084eb..0ba7a2de0a 100644
--- a/apps/database.c
+++ b/apps/database.c
@@ -466,28 +466,29 @@ void clearruntimeinfo(struct mp3entry *id) {
466} 466}
467 467
468void loadruntimeinfo(struct mp3entry *id) 468void loadruntimeinfo(struct mp3entry *id)
469{ int blahthisiscrapandyouknowitcauseidonthavetimetofindaproperwaytofixitsoblah; 469{
470 clearruntimeinfo(id); 470 clearruntimeinfo(id);
471 clearfileentryinfo(id); 471 clearfileentryinfo(id);
472 if(!getfentrybyfilename(id)) { 472 if(!getfentrybyfilename(id)) {
473 logf("tagdb fail: %s",id->path); 473 logf("tagdb fail: %s",id->path);
474 return; /* file is not in tagdatabase, could not load. */ 474 return; /* file is not in tagdatabase, could not load. */
475 } 475 }
476 if(id->rundbentryoffset!=-1&&id->rundbentryoffset<rundbsize) { 476 if(id->rundbentryoffset!=-1 && id->rundbentryoffset<rundbsize) {
477 logf("load rundbentry: 0x%x",id->rundbentryoffset); 477 logf("load rundbentry: 0x%x", id->rundbentryoffset);
478 getrundbentrybyoffset(id,id->rundbentryoffset); 478 getrundbentrybyoffset(id, id->rundbentryoffset);
479 if(id->filehash!=id->rundbhash) { 479 if(id->filehash != id->rundbhash) {
480 logf("Rundb: Hash mismatch. trying to repair entry.", 480 logf("Rundb: Hash mismatch. trying to repair entry.",
481 id->filehash,id->rundbhash); 481 id->filehash, id->rundbhash);
482 findrundbentry(id); 482 findrundbentry(id);
483 } 483 }
484 } 484 }
485#ifdef ROCKBOX_HAS_LOGF
485 else { 486 else {
486 if(!findrundbentry(id)) { 487 if(!findrundbentry(id)) {
487 logf("rundb:no entry and not found."); 488 logf("rundb:no entry and not found.");
488 blahthisiscrapandyouknowitcauseidonthavetimetofindaproperwaytofixitsoblah=1; 489 }
489 }
490 } 490 }
491#endif
491} 492}
492 493
493int findrundbentry(struct mp3entry *id) { 494int findrundbentry(struct mp3entry *id) {