From bd8cc69893e49ff0615c326301d8d2a5a49bee7e Mon Sep 17 00:00:00 2001 From: mailwl Date: Thu, 7 Apr 2016 11:26:12 +0300 Subject: ac:u: stub CloseAsync; check memory size aling in svc:GetProcessInfo(type=2) --- src/core/hle/svc.cpp | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src/core/hle/svc.cpp') diff --git a/src/core/hle/svc.cpp b/src/core/hle/svc.cpp index ae54afb1c..1112a905e 100644 --- a/src/core/hle/svc.cpp +++ b/src/core/hle/svc.cpp @@ -860,6 +860,10 @@ static ResultCode GetProcessInfo(s64* out, Handle process_handle, u32 type) { // TODO(yuriks): Type 0 returns a slightly higher number than type 2, but I'm not sure // what's the difference between them. *out = process->heap_used + process->linear_heap_used + process->misc_memory_used; + if(*out % Memory::PAGE_SIZE != 0) { + LOG_ERROR(Kernel_SVC, "called, memory size not page-aligned"); + return ERR_MISALIGNED_SIZE; + } break; case 1: case 3: -- cgit v1.2.3