Appended '/' to the switch path checked for NRO-auto-detect.

This commit is contained in:
yellows8 2018-02-27 22:14:56 -05:00
parent 8f734a631d
commit dd78d0f8d7

View File

@ -143,8 +143,8 @@ bool menuEntryLoad(menuEntry_s* me, const char* name, bool shortcut) {
snprintf(tempbuf, sizeof(tempbuf)-1, "%.*s/%.*s.nro", (int)sizeof(tempbuf)/2, me->path, (int)sizeof(tempbuf)/2-7, name);
bool found = fileExists(tempbuf);
//Use the first .nro found in the directory, if there's only 1 NRO in the directory. Only used for paths which start with "sdmc:/switch".
if (!found && strncmp(me->path, "sdmc:/switch", 12)==0) {
//Use the first .nro found in the directory, if there's only 1 NRO in the directory. Only used for paths starting with "sdmc:/switch/".
if (!found && strncmp(me->path, "sdmc:/switch/", 13)==0) {
DIR* dir;
struct dirent* dp;
u32 nro_count=0;