*Added network shutdown before launching games.

*Fixed playing games online (WC24) with that
This commit is contained in:
dimok321 2010-12-05 19:24:32 +00:00
parent 71c47c23bb
commit 449eae85bf
5 changed files with 16 additions and 25 deletions

View File

@ -2,8 +2,8 @@
<app version="1">
<name> USB Loader GX</name>
<coder>USB Loader GX Team</coder>
<version>1.0 r1007</version>
<release_date>201012031819</release_date>
<version>1.0 r1010</version>
<release_date>201012051910</release_date>
<short_description>Loads games from USB-devices</short_description>
<long_description>USB Loader GX is a libwiigui based USB iso loader with a wii-like GUI. You can install games to your HDDs and boot them with shorter loading times.
The interactive GUI is completely controllable with WiiMote, Classic Controller or GC Controller.

File diff suppressed because one or more lines are too long

View File

@ -66,6 +66,16 @@ void Initialize_Network(void)
}
}
/****************************************************************************
* DeinitNetwork
***************************************************************************/
void DeinitNetwork(void)
{
net_wc24cleanup();
net_deinit();
networkinitialized = false;
}
/****************************************************************************
* Check if network was initialised
***************************************************************************/
@ -90,28 +100,6 @@ char * GetIncommingIP(void)
return incommingIP;
}
/****************************************************************************
* Get network IP
***************************************************************************/
bool ShutdownWC24()
{
bool onlinefix = IsNetworkInit();
if (onlinefix)
{
s32 kd_fd, ret;
STACK_ALIGN( u8, kd_buf, 0x20, 32 );
kd_fd = IOS_Open("/dev/net/kd/request", 0);
if (kd_fd >= 0)
{
ret = IOS_Ioctl(kd_fd, 7, NULL, 0, kd_buf, 0x20);
if (ret >= 0) onlinefix = false; // fixed no IOS reload needed
IOS_Close(kd_fd);
}
}
return onlinefix;
}
s32 network_request(s32 connect, const char * request, char * filename)
{
char buf[1024];

View File

@ -10,6 +10,7 @@
#define NETWORKBLOCKSIZE 5*1024 //5KB
void Initialize_Network(void);
void DeinitNetwork(void);
bool IsNetworkInit(void);
char * GetNetworkIP(void);
char * GetIncommingIP(void);

View File

@ -6,6 +6,7 @@
#include "settings/CSettings.h"
#include "settings/newtitles.h"
#include "language/gettext.h"
#include "network/networkops.h"
#include "utils/ResourceManager.h"
#include "FontSystem.h"
#include "audio.h"
@ -80,6 +81,7 @@ void AppCleanUp(void)
CloseXMLDatabase();
ClearFontData();
NewTitles::DestroyInstance();
DeinitNetwork();
StopGX();
ShutdownAudio();