mirror of
https://github.com/wiidev/usbloadergx.git
synced 2024-11-18 01:09:16 +01:00
oops
This commit is contained in:
parent
bb234a9a51
commit
6012536f67
@ -130,6 +130,7 @@ int isInserted( const char *path )
|
||||
return __io_sdhc.isInserted() || __io_wiisd.isInserted();
|
||||
}
|
||||
|
||||
static u8 sdIsInited = 0;
|
||||
int SDCard_Init()
|
||||
{
|
||||
#ifdef DEBUG_FAT
|
||||
@ -142,6 +143,7 @@ int SDCard_Init()
|
||||
{
|
||||
fat_sd_mount = MOUNT_SD;
|
||||
fat_sd_sec = _FAT_startSector;
|
||||
sdIsInited = 1;
|
||||
#ifdef DEBUG_FAT
|
||||
gprintf( ":1\n" );
|
||||
#endif
|
||||
@ -151,6 +153,7 @@ int SDCard_Init()
|
||||
{
|
||||
fat_sd_mount = MOUNT_SDHC;
|
||||
fat_sd_sec = _FAT_startSector;
|
||||
sdIsInited = 1;
|
||||
#ifdef DEBUG_FAT
|
||||
gprintf( ":1\n" );
|
||||
#endif
|
||||
@ -165,13 +168,17 @@ int SDCard_Init()
|
||||
void SDCard_deInit()
|
||||
{
|
||||
#ifdef DEBUG_FAT
|
||||
gprintf( "SDCard_deInit(): " );
|
||||
gprintf( "SDCard_deInit( %d ): ", sdIsInited );
|
||||
#endif
|
||||
//closing all open Files write back the cache and then shutdown em!
|
||||
if( sdIsInited )
|
||||
{
|
||||
fatUnmount( "SD:/" );
|
||||
|
||||
fat_sd_mount = MOUNT_NONE;
|
||||
fat_sd_sec = 0;
|
||||
sdIsInited = 0;
|
||||
}
|
||||
#ifdef DEBUG_FAT
|
||||
gprintf( "ok\n" );
|
||||
#endif
|
||||
|
@ -1726,7 +1726,10 @@ void game_set( char *name, char *val )
|
||||
}
|
||||
if ( strcmp( "returnTo", opt_name ) == 0 )
|
||||
{
|
||||
strlcpy( game->returnTo, opt_val, sizeof( game->returnTo ) );
|
||||
if ( sscanf( opt_val, "%hd", &opt_c ) == 1 )
|
||||
{
|
||||
game->returnTo = opt_c;
|
||||
}
|
||||
}
|
||||
}
|
||||
// next opt
|
||||
@ -1893,7 +1896,7 @@ bool cfg_save_games()
|
||||
fprintf( f, "loadalternatedol:%d;", cfg_game[i].loadalternatedol );
|
||||
fprintf( f, "alternatedolstart:%d;", cfg_game[i].alternatedolstart );
|
||||
fprintf( f, "alternatedolname:%s;\n", cfg_game[i].alternatedolname );
|
||||
fprintf( f, "returnTo:%s;\n", cfg_game[i].returnTo );
|
||||
fprintf( f, "returnTo:%d;\n", cfg_game[i].returnTo );
|
||||
}
|
||||
fprintf( f, "# END\n" );
|
||||
fclose( f );
|
||||
|
@ -298,6 +298,7 @@ s32 Disc_IsWii( void )
|
||||
|
||||
s32 Disc_BootPartition( u64 offset, u8 videoselected, u8 cheat, u8 vipatch, u8 patchcountrystring, u8 error002fix, u8 alternatedol, u32 alternatedoloffset, u32 returnTo )
|
||||
{
|
||||
gprintf("booting partition IOS %u v%u\n", IOS_GetVersion(), IOS_GetRevision() );
|
||||
entry_point p_entry;
|
||||
|
||||
s32 ret;
|
||||
|
Loading…
Reference in New Issue
Block a user