File tree 5 files changed +32
-4
lines changed 5 files changed +32
-4
lines changed Original file line number Diff line number Diff line change @@ -34,7 +34,7 @@ INCLUDES := src
34
34
ROMFS := src/3ds/romfs
35
35
36
36
APP_TITLE=atari800
37
- APP_VERSION=0.3.7
37
+ APP_VERSION=0.3.8
38
38
APP_DESCRIPTION=\" Atari 8-bit computer emulator ($(APP_VERSION))\"
39
39
APP_AUTHOR=\" atari800 development team\"
40
40
ICON = src/3ds/banner/atari800-icon.png
@@ -218,7 +218,8 @@ $(BUILD):
218
218
clean:
219
219
@echo clean ...
220
220
@rm -fr $(BUILD) $(TARGET).3dsx $(OUTPUT).smdh $(TARGET).elf
221
- @rm -fr src/*.d src/*.o src/3ds/*.d src/3ds/*.o
221
+ @rm -fr src/*.d src/*.o src/3ds/*.d src/3ds/*.o src/codecs/*.d src/codecs/*.o
222
+ @rm -fr src/roms/*.d src/roms/*.o
222
223
223
224
224
225
#---------------------------------------------------------------------------------
Original file line number Diff line number Diff line change 405
405
#define PACKAGE_NAME "Atari800"
406
406
407
407
/* Define to the full name and version of this package. */
408
- #define PACKAGE_STRING "Atari800 git (2022-04-24 )"
408
+ #define PACKAGE_STRING "Atari800 git (2022-06-06 )"
409
409
410
410
/* Define to the one symbol short name of this package. */
411
411
#define PACKAGE_TARNAME "atari800"
414
414
#define PACKAGE_URL ""
415
415
416
416
/* Define to the version of this package. */
417
- #define PACKAGE_VERSION "3DS 0.3.6 "
417
+ #define PACKAGE_VERSION "3DS 0.3.8 "
418
418
419
419
/* Define to use page-based attribute array. */
420
420
#define PAGED_ATTRIB 1
Original file line number Diff line number Diff line change 24
24
25
25
#include <3ds.h>
26
26
#include <citro3d.h>
27
+ #include <malloc.h>
27
28
#include <stdio.h>
29
+ #include <stdlib.h>
28
30
#include <string.h>
29
31
30
32
/* Atari800 includes */
43
45
#include "videomode.h"
44
46
45
47
static bool PLATFORM_IsNew3DS ;
48
+ static u32 PLATFORM_NetworkInitialized = 0 ;
49
+ static u32 * PLATFORM_SocketBuffer ;
46
50
47
51
extern int dpad_as_keyboard ;
48
52
53
+ void PLATFORM_InitNetwork (void )
54
+ {
55
+ if (PLATFORM_NetworkInitialized == 0 ) {
56
+ PLATFORM_SocketBuffer = (u32 * ) memalign (0x1000 , 0x80000 );
57
+ PLATFORM_NetworkInitialized = 1 ;
58
+ if (PLATFORM_SocketBuffer != NULL ) {
59
+ if (socInit (PLATFORM_SocketBuffer , 0x80000 ) == 0 ) {
60
+ PLATFORM_NetworkInitialized = 2 ;
61
+ }
62
+ }
63
+ }
64
+ }
65
+
49
66
int PLATFORM_Configure (char * option , char * parameters )
50
67
{
51
68
if (strcmp (option , "N3DS_DPAD_MODE" ) == 0 )
@@ -92,6 +109,11 @@ int PLATFORM_Exit(int run_monitor)
92
109
if (run_monitor ) {
93
110
return 1 ;
94
111
} else {
112
+ if (PLATFORM_NetworkInitialized >= 2 ) {
113
+ socExit ();
114
+ free (PLATFORM_SocketBuffer );
115
+ }
116
+
95
117
N3DS_ExitVideo ();
96
118
97
119
romfsExit ();
Original file line number Diff line number Diff line change 13
13
14
14
/* This include file defines prototypes for platform-specific functions. */
15
15
16
+ void PLATFORM_InitNetwork (void );
17
+
16
18
int PLATFORM_Initialise (int * argc , char * argv []);
17
19
int PLATFORM_Exit (int run_monitor );
18
20
int PLATFORM_Keyboard (void );
Original file line number Diff line number Diff line change 73
73
*/
74
74
75
75
#include "config.h"
76
+ #include "platform.h"
76
77
#include <stdio.h>
77
78
#include <stdlib.h>
78
79
#include <string.h>
@@ -746,6 +747,8 @@ static void open_connection(char * address, int port)
746
747
#endif /* HAVE_WINDOWS_H */
747
748
if ((address != NULL ) && (strlen (address ) > 0 ))
748
749
{
750
+ PLATFORM_InitNetwork ();
751
+
749
752
close (rdev_fd );
750
753
close (sock );
751
754
do_once = 1 ;
You can’t perform that action at this time.
0 commit comments