Skip to content

Commit

Permalink
webMAN MOD 1.47.45
Browse files Browse the repository at this point in the history
- Fixed instant freeze using combos SELECT+L1 / SELECT+R1 used for mount last games (issue #891)
The bug was because the mount function was using _path0 as a pointer instead of a stack variable.
  • Loading branch information
aldostools committed Jul 23, 2023
1 parent 438a6f5 commit 21f46fd
Show file tree
Hide file tree
Showing 7 changed files with 6 additions and 3 deletions.
Binary file modified _Projects_/updater/pkgfiles/USRDIR/webftp_server_full.sprx
Binary file not shown.
Binary file modified _Projects_/updater/pkgfiles/USRDIR/webftp_server_noncobra.sprx
Binary file not shown.
Binary file not shown.
Binary file modified _Projects_/updater/update/dev_hdd0/plugins/webftp_server.sprx
Binary file not shown.
Binary file not shown.
6 changes: 3 additions & 3 deletions include/mount/mount.h
Original file line number Diff line number Diff line change
Expand Up @@ -1459,7 +1459,7 @@ static void mount_autoboot(void)
/***********************************************/
/* mount_thread parameters */
/***********************************************/
static char *_path0;
static char _path0[MAX_PATH_LEN];
static bool mount_ret = false;
/***********************************************/

Expand Down Expand Up @@ -1839,7 +1839,7 @@ static bool mount_game(const char *path, u8 action)
*/
if(is_mounting) return false; is_mounting = true;

_path0 = (char*)path;
strcpy(_path0, path);

sys_ppu_thread_t t_id;
sys_ppu_thread_create(&t_id, mount_thread, (u64)action, THREAD_PRIO_HIGH, THREAD_STACK_SIZE_MOUNT_GAME, SYS_PPU_THREAD_CREATE_JOINABLE, THREAD_NAME_CMD);
Expand All @@ -1849,7 +1849,7 @@ static bool mount_game(const char *path, u8 action)

close_ftp_sessions_idle();

_path0 = NULL;
_memset(_path0, sizeof(_path0));

return mount_ret;
}
3 changes: 3 additions & 0 deletions include/mount/patch_ps2demo.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#ifdef COBRA_ONLY
static void patch_ps2_demo(const char *iso_file)
{
// skip patch if using ps2_emu: 0x01 = CECH-A*, 0x02 = CECH-B
if((eid0_idps[0] & 0x00000000000000FF) <= 0x02 && !(webman_config->ps2emu)) return;

u32 offset, root;
char data[0x40];
char game_id[12]; _memset(game_id, sizeof(game_id));
Expand Down

0 comments on commit 21f46fd

Please sign in to comment.