diff options
author | Zeex <zeex@rocketmail.com> | 2018-11-22 05:29:35 +0600 |
---|---|---|
committer | Zeex <zeex@rocketmail.com> | 2018-11-22 05:29:35 +0600 |
commit | 12732c1d1d9b3b9febed99b5b5e4d625549f3098 (patch) | |
tree | cb0374781ed416244c6cf454fd1f02f7f5bb8909 | |
parent | dae419521cba2213a04ee8c80ebf07b58fd725a4 (diff) | |
download | subhook-12732c1d1d9b3b9febed99b5b5e4d625549f3098.zip subhook-12732c1d1d9b3b9febed99b5b5e4d625549f3098.tar.gz subhook-12732c1d1d9b3b9febed99b5b5e4d625549f3098.tar.bz2 |
Cleanup and code style fixse
-rw-r--r-- | subhook.c | 3 | ||||
-rw-r--r-- | subhook.h | 20 | ||||
-rw-r--r-- | subhook_private.h | 3 | ||||
-rw-r--r-- | subhook_unix.c | 3 | ||||
-rw-r--r-- | subhook_windows.c | 3 | ||||
-rw-r--r-- | subhook_x86.c | 3 |
6 files changed, 22 insertions, 13 deletions
@@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without @@ -101,9 +102,10 @@ typedef int (SUBHOOK_API *subhook_disasm_handler_t)( void *src, int *reloc_op_offset); -SUBHOOK_EXPORT subhook_t SUBHOOK_API subhook_new(void *src, - void *dst, - subhook_flags_t flags); +SUBHOOK_EXPORT subhook_t SUBHOOK_API subhook_new( + void *src, + void *dst, + subhook_flags_t flags); SUBHOOK_EXPORT void SUBHOOK_API subhook_free(subhook_t hook); SUBHOOK_EXPORT void *SUBHOOK_API subhook_get_src(subhook_t hook); @@ -114,14 +116,16 @@ SUBHOOK_EXPORT int SUBHOOK_API subhook_install(subhook_t hook); SUBHOOK_EXPORT int SUBHOOK_API subhook_is_installed(subhook_t hook); SUBHOOK_EXPORT int SUBHOOK_API subhook_remove(subhook_t hook); -/* Reads hook destination address from code. +/* + * Reads hook destination address from code. * - * This is useful when you don't know the address or want to check whether - * src is already hooked. + * This function may be useful when you don't know the address or want to + * check whether src is already hooked. */ SUBHOOK_EXPORT void *SUBHOOK_API subhook_read_dst(void *src); -/* Set a custom disassmbler function to use in place of the default one +/* + * Sets a custom disassmbler function to use in place of the default one * (subhook_disasm). * * The default function recognized a small st of x86 instructiosn commonly diff --git a/subhook_private.h b/subhook_private.h index ec0dcc0..9d54781 100644 --- a/subhook_private.h +++ b/subhook_private.h @@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/subhook_unix.c b/subhook_unix.c index 1c5260d..31f927e 100644 --- a/subhook_unix.c +++ b/subhook_unix.c @@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/subhook_windows.c b/subhook_windows.c index 13a514b..b1f0be6 100644 --- a/subhook_windows.c +++ b/subhook_windows.c @@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without diff --git a/subhook_x86.c b/subhook_x86.c index d5eae84..88062c8 100644 --- a/subhook_x86.c +++ b/subhook_x86.c @@ -1,4 +1,5 @@ -/* Copyright (c) 2012-2018 Zeex +/* + * Copyright (c) 2012-2018 Zeex * All rights reserved. * * Redistribution and use in source and binary forms, with or without |