Fix Mocha_StartUSBLogging definition

This commit is contained in:
Maschell 2022-07-22 13:48:43 +02:00
parent ecd4e07f90
commit c7047212aa
2 changed files with 10 additions and 9 deletions

View File

@ -50,14 +50,15 @@ MochaUtilsStatus Mocha_CheckAPIVersion(uint32_t *outVersion);
*/
MochaUtilsStatus Mocha_GetEnvironmentPath(char *environmentPathBuffer, uint32_t bufferLen);
/***
* Starts the MCP Thread in mocha to allows usage of /dev/iosuhax and wupclient
* @return MOCHA_RESULT_SUCCESS
/**
* Enables logging via USB (FTDI FT232 chipset only) via OSReport and friends. <br>
* @param notSkipExistingLogs If set to true, existing logs of this session won't be skipped.
* @return MOCHA_RESULT_SUCCESS: Logging via USB starts or has already been started<br>
* MOCHA_RESULT_LIB_UNINITIALIZED: Library was not initialized. Call Mocha_InitLibrary() before using this function.<br>
* MOCHA_RESULT_UNSUPPORTED_COMMAND: Command not supported by the currently loaded mocha version.<br>
* MOCHA_RESULT_UNKNOWN_ERROR: Failed to retrieve the environment path.
*/
MochaUtilsStatus Mocha_StartUSBLogging(bool avoidLogCatchup);
MochaUtilsStatus Mocha_StartUSBLogging(bool notSkipExistingLogs);
/**
* Gives a FSClient full permissions. <br>

View File

@ -80,7 +80,7 @@ MochaUtilsStatus Mocha_GetEnvironmentPath(char *environmentPathBuffer, uint32_t
return res;
}
MochaUtilsStatus Mocha_StartUSBLogging(bool avoidLogCatchup) {
MochaUtilsStatus Mocha_StartUSBLogging(bool notSkipExistingLogs) {
if (!mochaInitDone) {
return MOCHA_RESULT_LIB_UNINITIALIZED;
}
@ -92,7 +92,7 @@ MochaUtilsStatus Mocha_StartUSBLogging(bool avoidLogCatchup) {
if (mcpFd >= 0) {
ALIGN_0x40 uint32_t io_buffer[0x40 / 4];
io_buffer[0] = IPC_CUSTOM_START_USB_LOGGING;
io_buffer[1] = avoidLogCatchup;
io_buffer[1] = notSkipExistingLogs;
if (IOS_Ioctl(mcpFd, 100, io_buffer, 8, io_buffer, 0x4) == IOS_ERROR_OK) {
res = MOCHA_RESULT_SUCCESS;