Formatting

This commit is contained in:
Maschell 2021-09-23 18:52:20 +02:00
parent 35f046172e
commit f1b866f1ce
12 changed files with 73 additions and 76 deletions

View File

@ -1,18 +1,25 @@
void __init_wut_malloc(); void __init_wut_malloc();
void __init_wut_newlib(); void __init_wut_newlib();
void __init_wut_stdcpp(); void __init_wut_stdcpp();
void __init_wut_devoptab(); void __init_wut_devoptab();
void __attribute__((weak)) __init_wut_socket(); void __attribute__((weak)) __init_wut_socket();
void __fini_wut_malloc(); void __fini_wut_malloc();
void __fini_wut_newlib(); void __fini_wut_newlib();
void __fini_wut_stdcpp(); void __fini_wut_stdcpp();
void __fini_wut_devoptab(); void __fini_wut_devoptab();
void __attribute__((weak)) __fini_wut_socket(); void __attribute__((weak)) __fini_wut_socket();
void __attribute__((weak)) void __attribute__((weak))
__init_wut_() __init_wut_() {
{
__init_wut_malloc(); __init_wut_malloc();
__init_wut_newlib(); __init_wut_newlib();
__init_wut_stdcpp(); __init_wut_stdcpp();
@ -21,8 +28,7 @@ __init_wut_()
} }
void __attribute__((weak)) void __attribute__((weak))
__fini_wut_() __fini_wut_() {
{
__fini_wut_devoptab(); __fini_wut_devoptab();
__fini_wut_stdcpp(); __fini_wut_stdcpp();
__fini_wut_newlib(); __fini_wut_newlib();

View File

@ -1,5 +1,4 @@
#include <string.h> #include <string.h>
#include <stdio.h>
#include <coreinit/cache.h> #include <coreinit/cache.h>
#include <coreinit/thread.h> #include <coreinit/thread.h>
#include <coreinit/ios.h> #include <coreinit/ios.h>

View File

@ -110,8 +110,8 @@ static int ipc_ioctl(ipcmessage *message) {
memcpy(arguments, message->ioctl.buffer_in + 1, (size_arguments < 8 * 4) ? size_arguments : (8 * 4)); memcpy(arguments, message->ioctl.buffer_in + 1, (size_arguments < 8 * 4) ? size_arguments : (8 * 4));
// return error code as data // return error code as data
message->ioctl.buffer_io[0] = ((int (*const)(u32, u32, u32, u32, u32, u32, u32, u32)) (MCP_SVC_BASE + svc_id * 8))(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], message->ioctl.buffer_io[0] = ((int (*const)(u32, u32, u32, u32, u32, u32, u32, u32)) (MCP_SVC_BASE + svc_id * 8))(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4],
arguments[7]); arguments[5], arguments[6], arguments[7]);
} }
break; break;
} }

View File

@ -1,11 +1,5 @@
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
#include "wupserver.h" #include "wupserver.h"
#include "ipc.h" #include "ipc.h"
#include "svc.h"
#include "text.h"
#include "../../common/kernel_commands.h"
static int threadsStarted = 0; static int threadsStarted = 0;

View File

@ -21,7 +21,6 @@
#include "../../common/ipc_defs.h" #include "../../common/ipc_defs.h"
#include "fsa.h" #include "fsa.h"
#include "svc.h" #include "svc.h"
#include "utils.h"
#include <string.h> #include <string.h>
int (*const real_MCP_LoadFile)(ipcmessage *msg) = (void *) 0x0501CAA8 + 1; //+1 for thumb int (*const real_MCP_LoadFile)(ipcmessage *msg) = (void *) 0x0501CAA8 + 1; //+1 for thumb

View File

@ -55,7 +55,8 @@ static int serverCommandHandler(u32 *command_buffer, u32 length) {
// return error code as data // return error code as data
out_length = 8; out_length = 8;
command_buffer[1] = ((int (*const)(u32, u32, u32, u32, u32, u32, u32, u32)) (MCP_SVC_BASE + svc_id * 8))(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5], arguments[6], arguments[7]); command_buffer[1] = ((int (*const)(u32, u32, u32, u32, u32, u32, u32, u32)) (MCP_SVC_BASE + svc_id * 8))(arguments[0], arguments[1], arguments[2], arguments[3], arguments[4], arguments[5],
arguments[6], arguments[7]);
} }
break; break;
case 3: case 3:

View File

@ -1,6 +1,4 @@
#include <stdio.h> #include <cstring>
#include <string.h>
#include <string>
#include <coreinit/cache.h> #include <coreinit/cache.h>
#include <coreinit/ios.h> #include <coreinit/ios.h>