forked from len0rd/rockbox
parent
fffae07833
commit
272ce05396
2 changed files with 7 additions and 6 deletions
|
@ -1574,7 +1574,7 @@ static int retrieve_entries(struct tree_context *c, int offset, bool init)
|
|||
int i;
|
||||
int namebufused = 0;
|
||||
int total_count = 0;
|
||||
int special_entry_count = 0;
|
||||
c->special_entry_count = 0;
|
||||
int level = c->currextra;
|
||||
int tag;
|
||||
bool sort = false;
|
||||
|
@ -1691,7 +1691,7 @@ static int retrieve_entries(struct tree_context *c, int offset, bool init)
|
|||
dptr->customaction = ONPLAY_NO_CUSTOMACTION;
|
||||
dptr++;
|
||||
current_entry_count++;
|
||||
special_entry_count++;
|
||||
c->special_entry_count++;
|
||||
}
|
||||
if (offset <= 1)
|
||||
{
|
||||
|
@ -1701,7 +1701,7 @@ static int retrieve_entries(struct tree_context *c, int offset, bool init)
|
|||
dptr->customaction = ONPLAY_NO_CUSTOMACTION;
|
||||
dptr++;
|
||||
current_entry_count++;
|
||||
special_entry_count++;
|
||||
c->special_entry_count++;
|
||||
}
|
||||
|
||||
total_count += 2;
|
||||
|
@ -1839,8 +1839,8 @@ entry_skip_formatter:
|
|||
qsort_fn = sort_inverse ? strncasecmp_inv : strncasecmp;
|
||||
|
||||
struct tagentry *entries = get_entries(c);
|
||||
qsort(&entries[special_entry_count],
|
||||
current_entry_count - special_entry_count,
|
||||
qsort(&entries[c->special_entry_count],
|
||||
current_entry_count - c->special_entry_count,
|
||||
sizeof(struct tagentry),
|
||||
compare);
|
||||
}
|
||||
|
@ -1882,7 +1882,7 @@ entry_skip_formatter:
|
|||
if (strip)
|
||||
{
|
||||
dptr = get_entries(c);
|
||||
for (i = special_entry_count; i < current_entry_count; i++, dptr++)
|
||||
for (i = c->special_entry_count; i < current_entry_count; i++, dptr++)
|
||||
{
|
||||
int len = strlen(dptr->name);
|
||||
|
||||
|
|
|
@ -92,6 +92,7 @@ struct tree_context {
|
|||
#ifdef HAVE_TAGCACHE
|
||||
int currtable; /* db use */
|
||||
int currextra; /* db use */
|
||||
int special_entry_count; /* db use */
|
||||
#endif
|
||||
int sort_dir; /* directory sort order */
|
||||
int out_of_tree; /* shortcut from elsewhere */
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue