Fix whitespace

This commit is contained in:
shchmue 2019-03-07 11:06:32 -05:00
parent 867d2d6520
commit 8b42b1b184
7 changed files with 15 additions and 16 deletions

View File

@ -89,7 +89,7 @@ namespace Common {
} }
glyph_index = FT_Get_Char_Index(face, (FT_ULong)str[i]); glyph_index = FT_Get_Char_Index(face, (FT_ULong)str[i]);
if (R_FAILED(FT_Load_Glyph(face, glyph_index, FT_LOAD_COLOR) || if (R_FAILED(FT_Load_Glyph(face, glyph_index, FT_LOAD_COLOR) ||
FT_Render_Glyph(face->glyph, FT_RENDER_MODE_NORMAL) != 0)) FT_Render_Glyph(face->glyph, FT_RENDER_MODE_NORMAL) != 0))
{ {

View File

@ -89,7 +89,7 @@ byte_vector Key::aes_decrypt_ctr(const byte_vector &data, byte_vector iv) {
// used internally // used internally
size_t nc_off = 0; size_t nc_off = 0;
u8 stream_block[0x10]; u8 stream_block[0x10];
mbedtls_aes_context dec; mbedtls_aes_context dec;
mbedtls_aes_init(&dec); mbedtls_aes_init(&dec);
mbedtls_aes_setkey_enc(&dec, key.data(), length * 8); mbedtls_aes_setkey_enc(&dec, key.data(), length * 8);

View File

@ -82,7 +82,6 @@ void KeyLocation::get_from_memory(u64 tid, u8 seg_mask) {
addr = mem_info.addr + mem_info.size; addr = mem_info.addr + mem_info.size;
if (addr == 0) break; if (addr == 0) break;
} }
svcCloseHandle(debug_handle); svcCloseHandle(debug_handle);
} }

View File

@ -12,7 +12,7 @@ include $(DEVKITPRO)/libnx/switch_rules
# Also see "include/mbedtls/config.h" # Also see "include/mbedtls/config.h"
ARCH := -march=armv8-a+crypto -mtune=cortex-a57 -mtp=soft -fPIE ARCH := -march=armv8-a+crypto -mtune=cortex-a57 -mtp=soft -fPIE
CFLAGS := -g -Wall -O3 -ffunction-sections $(ARCH) $(DEFINES) CFLAGS := -g -Wall -O3 -ffunction-sections $(ARCH) $(DEFINES)
CFLAGS += -I ../include -D__SWITCH__ CFLAGS += -I ../include -D__SWITCH__
CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -std=gnu++11 CXXFLAGS := $(CFLAGS) -fno-rtti -fno-exceptions -std=gnu++11
ASFLAGS := -g $(ARCH) ASFLAGS := -g $(ARCH)

View File

@ -57,7 +57,7 @@ Result esCountCommonTicket(u32 *num_tickets)
} }
} }
return rc; return rc;
} }
Result esCountPersonalizedTicket(u32 *num_tickets) Result esCountPersonalizedTicket(u32 *num_tickets)
@ -94,23 +94,23 @@ Result esCountPersonalizedTicket(u32 *num_tickets)
} }
} }
return rc; return rc;
} }
Result esListCommonTicket(u32 *numRightsIdsWritten, NcmRightsId *outBuf, size_t bufSize) { Result esListCommonTicket(u32 *numRightsIdsWritten, NcmRightsId *outBuf, size_t bufSize) {
IpcCommand c; IpcCommand c;
ipcInitialize(&c); ipcInitialize(&c);
ipcAddRecvBuffer(&c, outBuf, bufSize, BufferType_Normal); ipcAddRecvBuffer(&c, outBuf, bufSize, BufferType_Normal);
struct { struct {
u64 magic; u64 magic;
u64 cmd_id; u64 cmd_id;
} *raw; } *raw;
raw = ipcPrepareHeader(&c, sizeof(*raw)); raw = ipcPrepareHeader(&c, sizeof(*raw));
raw->magic = SFCI_MAGIC; raw->magic = SFCI_MAGIC;
raw->cmd_id = 11; raw->cmd_id = 11;
Result rc = serviceIpcDispatch(&g_esSrv); Result rc = serviceIpcDispatch(&g_esSrv);
if (R_SUCCEEDED(rc)) { if (R_SUCCEEDED(rc)) {
@ -129,7 +129,7 @@ Result esListCommonTicket(u32 *numRightsIdsWritten, NcmRightsId *outBuf, size_t
if (numRightsIdsWritten) *numRightsIdsWritten = resp->num_rights_ids_written; if (numRightsIdsWritten) *numRightsIdsWritten = resp->num_rights_ids_written;
} }
} }
return rc; return rc;
} }
@ -137,16 +137,16 @@ Result esListPersonalizedTicket(u32 *numRightsIdsWritten, NcmRightsId *outBuf, s
IpcCommand c; IpcCommand c;
ipcInitialize(&c); ipcInitialize(&c);
ipcAddRecvBuffer(&c, outBuf, bufSize, BufferType_Normal); ipcAddRecvBuffer(&c, outBuf, bufSize, BufferType_Normal);
struct { struct {
u64 magic; u64 magic;
u64 cmd_id; u64 cmd_id;
} *raw; } *raw;
raw = ipcPrepareHeader(&c, sizeof(*raw)); raw = ipcPrepareHeader(&c, sizeof(*raw));
raw->magic = SFCI_MAGIC; raw->magic = SFCI_MAGIC;
raw->cmd_id = 12; raw->cmd_id = 12;
Result rc = serviceIpcDispatch(&g_esSrv); Result rc = serviceIpcDispatch(&g_esSrv);
if (R_SUCCEEDED(rc)) { if (R_SUCCEEDED(rc)) {
@ -165,6 +165,6 @@ Result esListPersonalizedTicket(u32 *numRightsIdsWritten, NcmRightsId *outBuf, s
if (numRightsIdsWritten) *numRightsIdsWritten = resp->num_rights_ids_written; if (numRightsIdsWritten) *numRightsIdsWritten = resp->num_rights_ids_written;
} }
} }
return rc; return rc;
} }

View File

@ -19,7 +19,7 @@ extern "C" {
#define unlikely(x) __builtin_expect(!!(x), 0) #define unlikely(x) __builtin_expect(!!(x), 0)
void sha256_block_data_order (uint32_t *ctx, const void *in, size_t num); void sha256_block_data_order (uint32_t *ctx, const void *in, size_t num);
int sha256_init(struct sha256_state *sctx) int sha256_init(struct sha256_state *sctx)
{ {
sctx->state[0] = SHA256_H0; sctx->state[0] = SHA256_H0;

View File

@ -24,7 +24,7 @@ sha256_block_data_order:
str q9, [sp, #32] str q9, [sp, #32]
str q10, [sp, #48] str q10, [sp, #48]
ld1 {v28.4s-v31.4s}, [x3], #64 ld1 {v28.4s-v31.4s}, [x3], #64
.Lsha256loop: .Lsha256loop:
ld1 {v5.16b-v8.16b}, [x1], #64 ld1 {v5.16b-v8.16b}, [x1], #64