]> granicus.if.org Git - php/commitdiff
- Drop one cache related function which is not really neccessary
authorMarcus Boerger <helly@php.net>
Wed, 12 Oct 2005 22:45:15 +0000 (22:45 +0000)
committerMarcus Boerger <helly@php.net>
Wed, 12 Oct 2005 22:45:15 +0000 (22:45 +0000)
ext/pcre/php_pcre.c
ext/pcre/php_pcre.h

index 8b74cf34d314dc2c66ff6f2113091fe32073a761..20a53efae57a9645b885eac5a63db838b0cd2c16 100644 (file)
@@ -124,9 +124,9 @@ static int pcre_clean_cache(void *data, void *arg TSRMLS_DC)
 }
 /* }}} */
 
-/* {{{ pcre_get_compiled_regex_cache_ex
+/* {{{ pcre_get_compiled_regex_cache
  */
-static pcre_cache_entry* pcre_get_compiled_regex_cache_ex(char *regex, int regex_len, pcre_extra **extra, int *preg_options, int *compile_options TSRMLS_DC)
+PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int regex_len, pcre_extra **extra, int *preg_options, int *compile_options TSRMLS_DC)
 {
        pcre                            *re = NULL;
        int                                      coptions = 0;
@@ -335,7 +335,7 @@ static pcre_cache_entry* pcre_get_compiled_regex_cache_ex(char *regex, int regex
 PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int *preg_options TSRMLS_DC)
 {
        int compile_options;
-       pcre_cache_entry * pce = pcre_get_compiled_regex_cache_ex(regex, strlen(regex), extra, preg_options, &compile_options TSRMLS_CC);
+       pcre_cache_entry * pce = pcre_get_compiled_regex_cache(regex, strlen(regex), extra, preg_options, &compile_options TSRMLS_CC);
        
        return pce ? pce->re : NULL;
 }
@@ -345,23 +345,12 @@ PHPAPI pcre* pcre_get_compiled_regex(char *regex, pcre_extra **extra, int *preg_
  */
 PHPAPI pcre* pcre_get_compiled_regex_ex(char *regex, pcre_extra **extra, int *preg_options, int *compile_options TSRMLS_DC)
 {
-       pcre_cache_entry * pce = pcre_get_compiled_regex_cache_ex(regex, strlen(regex), extra, preg_options, compile_options TSRMLS_CC);
+       pcre_cache_entry * pce = pcre_get_compiled_regex_cache(regex, strlen(regex), extra, preg_options, compile_options TSRMLS_CC);
        
        return pce ? pce->re : NULL;
 }
 /* }}} */
 
-/* {{{ pcre_get_compiled_regex_cache
- */
-PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int regex_len TSRMLS_DC)
-{
-       pcre_extra *extra;
-       int preg_options;
-       int compile_options;
-       return pcre_get_compiled_regex_cache_ex(regex, regex_len, &extra, &preg_options, &compile_options TSRMLS_CC);
-}
-/* }}} */
-
 /* {{{ add_offset_pair */
 static inline void add_offset_pair(zval *result, char *str, int len, int offset, char *name)
 {
index 8d1f8f62fed75c61fa4df06506323bf5f1f7ad96..cc9685d09b1bc91cf0dfefc0e2bb3dabb02b768a 100644 (file)
@@ -60,7 +60,7 @@ typedef struct {
        int refcount;
 } pcre_cache_entry;
 
-PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int regex_len TSRMLS_DC);
+PHPAPI pcre_cache_entry* pcre_get_compiled_regex_cache(char *regex, int regex_len, pcre_extra **extra, int *preg_options, int *compile_options  TSRMLS_DC);
 
 ZEND_BEGIN_MODULE_GLOBALS(pcre)
        HashTable pcre_cache;