user reported via bugzilla: http://bugs.gentoo.org/show_bug.cgi?id=78597
Tobias Minich <[EMAIL PROTECTED]> writes:
Entice is quite nice, but viewing directories is currently a pita since it
orders file in directory order (=no real order at all). I modded the source
so files are ordered by name.
(I always forget how to prepare proper patches so I'll attach just the
modified function from entice.c)
-mike
void
entice_file_add_dir_job_cb(void *data)
{
char buf[PATH_MAX], *file = NULL;
struct dirent **namelist;
int n, i = 0;
if (data)
{
file = (char *) data;
n = scandir(data, &namelist, 0, alphasort);
while (i < n)
{
if (!strcmp(namelist[i]->d_name, ".") || !strcmp(namelist[i]->d_name, "..")
|| (namelist[i]->d_name[0] == '.'))
{
i++;
continue;
}
snprintf(buf, PATH_MAX, "%s/%s", file, namelist[i]->d_name);
if (!entice_file_is_dir(buf))
entice_file_add_job_cb(buf, IPC_FILE_APPEND);
free(namelist[i]);
i++;
}
free(namelist);
}
}