hekate/nyx: use updated dirlist
This commit is contained in:
@@ -65,7 +65,7 @@ static int _config_kip1(launch_ctxt_t *ctxt, const char *value)
|
||||
|
||||
u32 dirlen = 0;
|
||||
dir[strlen(dir) - 2] = 0;
|
||||
char *filelist = dirlist(dir, "*.kip*", false, false);
|
||||
dirlist_t *filelist = dirlist(dir, "*.kip*", false, false);
|
||||
|
||||
strcat(dir, "/");
|
||||
dirlen = strlen(dir);
|
||||
@@ -75,10 +75,10 @@ static int _config_kip1(launch_ctxt_t *ctxt, const char *value)
|
||||
{
|
||||
while (true)
|
||||
{
|
||||
if (!filelist[i * 256])
|
||||
if (!filelist->name[i])
|
||||
break;
|
||||
|
||||
strcpy(dir + dirlen, &filelist[i * 256]);
|
||||
strcpy(dir + dirlen, filelist->name[i]);
|
||||
|
||||
merge_kip_t *mkip1 = (merge_kip_t *)malloc(sizeof(merge_kip_t));
|
||||
mkip1->kip1 = sd_file_read(dir, &size);
|
||||
|
||||
@@ -257,9 +257,9 @@ static void _launch_payloads()
|
||||
{
|
||||
u8 max_entries = 61;
|
||||
ment_t *ments = NULL;
|
||||
char *filelist = NULL;
|
||||
char *file_sec = NULL;
|
||||
char *dir = NULL;
|
||||
dirlist_t *filelist = NULL;
|
||||
|
||||
gfx_clear_grey(0x1B);
|
||||
gfx_con_setpos(0, 0);
|
||||
@@ -286,11 +286,11 @@ static void _launch_payloads()
|
||||
|
||||
while (true)
|
||||
{
|
||||
if (i > max_entries || !filelist[i * 256])
|
||||
if (i > max_entries || !filelist->name[i])
|
||||
break;
|
||||
ments[i + 2].type = INI_CHOICE;
|
||||
ments[i + 2].caption = &filelist[i * 256];
|
||||
ments[i + 2].data = &filelist[i * 256];
|
||||
ments[i + 2].caption = filelist->name[i];
|
||||
ments[i + 2].data = filelist->name[i];
|
||||
|
||||
i++;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user