php_syslog.h 1.5 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344
  1. /*
  2. +----------------------------------------------------------------------+
  3. | Copyright (c) The PHP Group |
  4. +----------------------------------------------------------------------+
  5. | This source file is subject to version 3.01 of the PHP license, |
  6. | that is bundled with this package in the file LICENSE, and is |
  7. | available through the world-wide-web at the following url: |
  8. | https://www.php.net/license/3_01.txt |
  9. | If you did not receive a copy of the PHP license and are unable to |
  10. | obtain it through the world-wide-web, please send a note to |
  11. | license@php.net so we can mail you a copy immediately. |
  12. +----------------------------------------------------------------------+
  13. | Author: |
  14. +----------------------------------------------------------------------+
  15. */
  16. #ifndef PHP_SYSLOG_H
  17. #define PHP_SYSLOG_H
  18. #include "php.h"
  19. #ifdef PHP_WIN32
  20. #include "win32/syslog.h"
  21. #else
  22. #include <php_config.h>
  23. #ifdef HAVE_SYSLOG_H
  24. #include <syslog.h>
  25. #endif
  26. #endif
  27. /* Syslog filters */
  28. #define PHP_SYSLOG_FILTER_ALL 0
  29. #define PHP_SYSLOG_FILTER_NO_CTRL 1
  30. #define PHP_SYSLOG_FILTER_ASCII 2
  31. #define PHP_SYSLOG_FILTER_RAW 3
  32. BEGIN_EXTERN_C()
  33. PHPAPI void php_syslog_str(int priority, const zend_string* message);
  34. PHPAPI void php_syslog(int, const char *format, ...);
  35. PHPAPI void php_openlog(const char *, int, int);
  36. PHPAPI void php_closelog(void);
  37. END_EXTERN_C()
  38. #endif