Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(4)

Unified Diff: fusl/src/mman/mprotect.c

Issue 1714623002: [fusl] clang-format fusl (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: headers too Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: fusl/src/mman/mprotect.c
diff --git a/fusl/src/mman/mprotect.c b/fusl/src/mman/mprotect.c
index 535787b9ec527bb12acbb80a53aadc4ab760c7b3..2a3212cc1fbef9074cbee3b4b687aafac7b31c0b 100644
--- a/fusl/src/mman/mprotect.c
+++ b/fusl/src/mman/mprotect.c
@@ -2,12 +2,11 @@
#include "libc.h"
#include "syscall.h"
-int __mprotect(void *addr, size_t len, int prot)
-{
- size_t start, end;
- start = (size_t)addr & -PAGE_SIZE;
- end = (size_t)((char *)addr + len + PAGE_SIZE-1) & -PAGE_SIZE;
- return syscall(SYS_mprotect, start, end-start, prot);
+int __mprotect(void* addr, size_t len, int prot) {
+ size_t start, end;
+ start = (size_t)addr & -PAGE_SIZE;
+ end = (size_t)((char*)addr + len + PAGE_SIZE - 1) & -PAGE_SIZE;
+ return syscall(SYS_mprotect, start, end - start, prot);
}
weak_alias(__mprotect, mprotect);

Powered by Google App Engine
This is Rietveld 408576698