Skip to content

Commit

Permalink
fix exit sequence
Browse files Browse the repository at this point in the history
  • Loading branch information
WinterMute committed Jun 7, 2020
1 parent e096dad commit b168032
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
1 change: 0 additions & 1 deletion libraries/wutcrt/crt0_rpl.s
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,6 @@ unload:
lwz 3, 0xC(1)
lwz 4, 0x10(1)
bl rpl_entry
bl __fini_wut
addi 1, 1, 0x14
b exit

1 change: 0 additions & 1 deletion libraries/wutcrt/crt0_rpx.s
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,5 @@ __rpx_start:
lwz 3, 0xC(1)
lwz 4, 0x10(1)
bl main
bl __fini_wut
addi 1, 1, 0x14
b exit
4 changes: 3 additions & 1 deletion libraries/wutnewlib/wut_newlib.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
#include <coreinit/exit.h>

void(*__wut_exit)(int rc);
extern void __fini_wut(void);

int __syscall_lock_init(int *lock, int recursive) {
return __wut_lock_init(lock,recursive);
Expand All @@ -19,7 +20,8 @@ int __syscall_lock_acquire(int *lock) {
return __wut_lock_acquire(lock);
}

void __syscall_exit(int rc) {
void __syscall_exit(int rc) {
__fini_wut();
__wut_exit(rc);
}

Expand Down

0 comments on commit b168032

Please sign in to comment.