aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorvanhauser-thc <vh@thc.org>2021-04-04 20:05:02 +0200
committervanhauser-thc <vh@thc.org>2021-04-04 20:05:02 +0200
commit3c846859eef4d17d2587ea28db83c680b51723a7 (patch)
tree4e394e959886ebad1889069958949623b9fce4ba /include
parentc23183f1dc39ce0792a879065e6aea33a4c571f8 (diff)
downloadafl++-3c846859eef4d17d2587ea28db83c680b51723a7.tar.gz
cleanup
Diffstat (limited to 'include')
-rw-r--r--include/android-ashmem.h16
1 files changed, 9 insertions, 7 deletions
diff --git a/include/android-ashmem.h b/include/android-ashmem.h
index 44fe556a..1bfd3220 100644
--- a/include/android-ashmem.h
+++ b/include/android-ashmem.h
@@ -13,12 +13,14 @@
#include <stdio.h>
#define ASHMEM_DEVICE "/dev/ashmem"
-int shmdt(const void* address) {
-#if defined(SYS_shmdt)
+int shmdt(const void *address) {
+
+ #if defined(SYS_shmdt)
return syscall(SYS_shmdt, address);
-#else
+ #else
return syscall(SYS_ipc, SHMDT, 0, 0, 0, address, 0);
-#endif
+ #endif
+
}
int shmctl(int __shmid, int __cmd, struct shmid_ds *__buf) {
@@ -26,7 +28,7 @@ int shmctl(int __shmid, int __cmd, struct shmid_ds *__buf) {
int ret = 0;
if (__cmd == IPC_RMID) {
- int length = ioctl(__shmid, ASHMEM_GET_SIZE, NULL);
+ int length = ioctl(__shmid, ASHMEM_GET_SIZE, NULL);
struct ashmem_pin pin = {0, length};
ret = ioctl(__shmid, ASHMEM_UNPIN, &pin);
close(__shmid);
@@ -77,6 +79,6 @@ void *shmat(int __shmid, const void *__shmaddr, int __shmflg) {
}
- #endif /* !_ANDROID_ASHMEM_H */
-#endif /* !__ANDROID__ */
+ #endif /* !_ANDROID_ASHMEM_H */
+#endif /* !__ANDROID__ */