mirror of
https://github.com/wiiu-env/wut.git
synced 2024-12-13 04:22:37 +01:00
Merge pull request #56 from CreeperMario/unrelated-fixes
Various small fixes
This commit is contained in:
commit
dd73b95579
@ -11,4 +11,6 @@ target_link_libraries(triangle
|
||||
defaultheap
|
||||
gx2
|
||||
gfd
|
||||
proc_ui)
|
||||
nsysnet
|
||||
proc_ui
|
||||
sysapp)
|
||||
|
@ -113,7 +113,7 @@ exit:
|
||||
WHBLogPrintf("Exiting...");
|
||||
GX2RDestroyBufferEx(&positionBuffer, 0);
|
||||
GX2RDestroyBufferEx(&colourBuffer, 0);
|
||||
//WHBUnmountSdCard(); !! freezes on unmount for unkown reason !!
|
||||
WHBUnmountSdCard();
|
||||
WHBGfxShutdown();
|
||||
WHBProcShutdown();
|
||||
return result;
|
||||
|
@ -70,7 +70,7 @@ static int __libwut_lock_close(int *lock)
|
||||
|
||||
static int __libwut_lock_acquire(int *lock)
|
||||
{
|
||||
OSMutex *mutex = (OSMutex *)lock;
|
||||
OSMutex *mutex = (OSMutex *)*lock;
|
||||
if (!lock || *lock == 0) {
|
||||
return -1;
|
||||
}
|
||||
@ -81,7 +81,7 @@ static int __libwut_lock_acquire(int *lock)
|
||||
|
||||
static int __libwut_lock_release(int *lock)
|
||||
{
|
||||
OSMutex *mutex = (OSMutex *)lock;
|
||||
OSMutex *mutex = (OSMutex *)*lock;
|
||||
if (!lock || *lock == 0) {
|
||||
return -1;
|
||||
}
|
||||
|
21
src/libwhb/include/whb/log_cafe.h
Normal file
21
src/libwhb/include/whb/log_cafe.h
Normal file
@ -0,0 +1,21 @@
|
||||
#pragma once
|
||||
#include <wut.h>
|
||||
|
||||
/**
|
||||
* \defgroup whb_log_cafe Cafe OS System Log Output
|
||||
* \ingroup whb
|
||||
* @{
|
||||
*/
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
BOOL
|
||||
WHBLogCafeInit();
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
/** @} */
|
15
src/libwhb/src/log_cafe.c
Normal file
15
src/libwhb/src/log_cafe.c
Normal file
@ -0,0 +1,15 @@
|
||||
#include <coreinit/debug.h>
|
||||
#include <whb/log.h>
|
||||
|
||||
static void
|
||||
cafeLogHandler(const char * msg)
|
||||
{
|
||||
OSReport("%s\n", msg);
|
||||
}
|
||||
|
||||
BOOL
|
||||
WHBLogCafeInit()
|
||||
{
|
||||
WHBAddLogHandler(cafeLogHandler);
|
||||
return TRUE;
|
||||
}
|
@ -67,6 +67,8 @@ WHBUnmountSdCard()
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
FSInitCmdBlock(&cmd);
|
||||
|
||||
result = FSUnmount(&sClient, &cmd, sMountPath, -1);
|
||||
if (result < 0) {
|
||||
WHBLogPrintf("%s: FSUnmount error %d", __FUNCTION__, result);
|
||||
|
Loading…
Reference in New Issue
Block a user