Rockbox.org home
release
dev builds
extras
themes manual
wiki
device status forums
mailing lists
IRC bugs
patches
dev guide
translations



Rockbox mail archive

Subject: Search problem with tagcache: solved?!

Search problem with tagcache: solved?!

From: <yagvoc-web_at_yahoo.it>
Date: Thu, 11 May 2006 18:54:51 +0200 (CEST)

Dear all,
this is my first post on this mailing list and I would
like to say hello to everybody and thank you for your
great job.
Now let's come to a little problem.
I noticed that the "search by title" and "search by
album" were missing some files. I red some code and
noticed the following block in tagcache.c line 521
==============================================
        /* Check for conditions. */
        for (i = 0; i < tcs->clause_count; i++)
        {
            struct tagfile_entry tfe;
            int seek =
entry.tag_seek[tcs->clause[i]->tag];
==> char str[64];
            
            memset(str, 0, sizeof str);
            if
(!tagcache_is_numeric_tag(tcs->clause[i]->tag))
            {
                int fd =
tcs->idxfd[tcs->clause[i]->tag];
                lseek(fd, seek, SEEK_SET);
                read(fd, &tfe, sizeof(struct
tagfile_entry));
==> if (tfe.tag_length >=
(int)sizeof(str))
                {
                    logf("Too long tag read!");
                    break ;
                }

                read(fd, str, tfe.tag_length);
            }
            
            if (!check_against_clause(seek, str,
tcs->clause[i]))
                break ;
        }
===============================================
The lines highlighted with the ==> are causing the
error because the skipped files have tags longer than
64 chars. Is there any way to raise this number? I
tried to compile and run on my H120 a new version with
char str[128] and, after 2 days, I got no problem.
What do you think of this?

Thank you in advance
Gaetano




        

        
                
___________________________________
Yahoo! Mail: gratis 1GB per i messaggi e allegati da 10MB
http://mail.yahoo.it
Received on 2006-05-11

Page template was last modified "Tue Sep 7 00:00:02 2021" The Rockbox Crew -- Privacy Policy