Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor #5

Merged
merged 4 commits into from
Jul 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions php_rayaop.h
Original file line number Diff line number Diff line change
Expand Up @@ -50,10 +50,6 @@ extern zend_module_entry rayaop_module_entry;
#define PHP_RAYAOP_DEBUG_PRINT(fmt, ...) /* Do nothing */
#endif

/* Error codes */
#define RAYAOP_ERROR_MEMORY_ALLOCATION 1 /* Error code for memory allocation */
#define RAYAOP_ERROR_HASH_UPDATE 2 /* Error code for hash update */

/* Structure to hold intercept information */
typedef struct _php_rayaop_intercept_info {
zend_string *class_name; /* Class name to intercept */
Expand All @@ -79,7 +75,7 @@ void php_rayaop_free_intercept_info(zval *zv); /* Function to free intercept inf

#ifdef RAYAOP_DEBUG /* If debug mode is enabled */
void php_rayaop_debug_print_zval(zval *value); /* Function to debug print zval value */
void php_rayaop_dump_intercept_info(void); /* Function to dump intercept information */
static void php_rayaop_dump_intercept_info(void); /* Function to dump intercept information */
#endif

ZEND_BEGIN_MODULE_GLOBALS(rayaop)
Expand All @@ -96,4 +92,6 @@ ZEND_END_MODULE_GLOBALS(rayaop) /* End of rayaop module global variables */
#define RAYAOP_G(v) (rayaop_globals.v)
#endif

#endif /* End of header guard */
ZEND_EXTERN_MODULE_GLOBALS(rayaop)

#endif /* End of header guard */
2 changes: 2 additions & 0 deletions rayaop.c
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@
#define RAYAOP_QUIET 0
#endif

// #define RAYAOP_DEBUG

#include "php_rayaop.h" /* Include header file for RayAOP extension */

/* Declaration of module global variables */
Expand Down
Loading