diff options
author | Sebastien Helleu <flashcode@flashtux.org> | 2012-01-26 18:18:20 +0100 |
---|---|---|
committer | Sebastien Helleu <flashcode@flashtux.org> | 2012-01-26 18:18:20 +0100 |
commit | 9347bae9623a5aa26436c7a822e9b8c1d39c14f2 (patch) | |
tree | 731205227618ca62574713e157cce38e3e23a90a | |
parent | 9a821b9d3cd5a9970520a742472547e7bb78ae24 (diff) | |
download | weechat-9347bae9623a5aa26436c7a822e9b8c1d39c14f2.zip |
api: replace type "regex_t *" by "void *" in function string_regcomp (fix ruby compilation with autotools)
-rw-r--r-- | doc/en/weechat_plugin_api.en.txt | 2 | ||||
-rw-r--r-- | doc/fr/weechat_plugin_api.fr.txt | 2 | ||||
-rw-r--r-- | doc/it/weechat_plugin_api.it.txt | 2 | ||||
-rw-r--r-- | src/core/wee-string.c | 4 | ||||
-rw-r--r-- | src/core/wee-string.h | 2 | ||||
-rw-r--r-- | src/plugins/weechat-plugin.h | 3 |
6 files changed, 7 insertions, 8 deletions
diff --git a/doc/en/weechat_plugin_api.en.txt b/doc/en/weechat_plugin_api.en.txt index 979c1438a..77e24c607 100644 --- a/doc/en/weechat_plugin_api.en.txt +++ b/doc/en/weechat_plugin_api.en.txt @@ -1090,7 +1090,7 @@ Prototype: [source,C] ---------------------------------------- -int weechat_string_regcomp (regex_t *preg, const char *regex, int default_flags) +int weechat_string_regcomp (void *preg, const char *regex, int default_flags) ---------------------------------------- Arguments: diff --git a/doc/fr/weechat_plugin_api.fr.txt b/doc/fr/weechat_plugin_api.fr.txt index 187f0fed5..0e953ab9f 100644 --- a/doc/fr/weechat_plugin_api.fr.txt +++ b/doc/fr/weechat_plugin_api.fr.txt @@ -1105,7 +1105,7 @@ Prototype : [source,C] ---------------------------------------- -int weechat_string_regcomp (regex_t *preg, const char *regex, int default_flags) +int weechat_string_regcomp (void *preg, const char *regex, int default_flags) ---------------------------------------- Paramètres : diff --git a/doc/it/weechat_plugin_api.it.txt b/doc/it/weechat_plugin_api.it.txt index b1fe79834..2c2c51689 100644 --- a/doc/it/weechat_plugin_api.it.txt +++ b/doc/it/weechat_plugin_api.it.txt @@ -1117,7 +1117,7 @@ Prototipo: [source,C] ---------------------------------------- -int weechat_string_regcomp (regex_t *preg, const char *regex, int default_flags) +int weechat_string_regcomp (void *preg, const char *regex, int default_flags) ---------------------------------------- Argomenti: diff --git a/src/core/wee-string.c b/src/core/wee-string.c index f063dfa5e..99b9dcf9c 100644 --- a/src/core/wee-string.c +++ b/src/core/wee-string.c @@ -804,13 +804,13 @@ string_regex_flags (const char *regex, int default_flags, int *flags) */ int -string_regcomp (regex_t *preg, const char *regex, int default_flags) +string_regcomp (void *preg, const char *regex, int default_flags) { const char *ptr_regex; int flags; ptr_regex = string_regex_flags (regex, default_flags, &flags); - return regcomp (preg, ptr_regex, flags); + return regcomp ((regex_t *)preg, ptr_regex, flags); } /* diff --git a/src/core/wee-string.h b/src/core/wee-string.h index 79a81c811..a000e65f3 100644 --- a/src/core/wee-string.h +++ b/src/core/wee-string.h @@ -51,7 +51,7 @@ extern char *string_convert_hex_chars (const char *string); extern char *string_mask_to_regex (const char *mask); extern const char *string_regex_flags (const char *regex, int default_flags, int *flags); -extern int string_regcomp (regex_t *preg, const char *regex, int default_flags); +extern int string_regcomp (void *preg, const char *regex, int default_flags); extern int string_has_highlight (const char *string, const char *highlight_words); extern int string_has_highlight_regex_compiled (const char *string, diff --git a/src/plugins/weechat-plugin.h b/src/plugins/weechat-plugin.h index 19384db95..2c5535e2f 100644 --- a/src/plugins/weechat-plugin.h +++ b/src/plugins/weechat-plugin.h @@ -26,7 +26,6 @@ #define __WEECHAT_WEECHAT_PLUGIN_H 1 #include <sys/types.h> -#include <regex.h> struct t_config_option; struct t_gui_window; @@ -229,7 +228,7 @@ struct t_weechat_plugin char *(*string_mask_to_regex) (const char *mask); const char *(*string_regex_flags) (const char *regex, int default_flags, int *flags); - int (*string_regcomp) (regex_t *preg, const char *regex, int default_flags); + int (*string_regcomp) (void *preg, const char *regex, int default_flags); int (*string_has_highlight) (const char *string, const char *highlight_words); int (*string_has_highlight_regex) (const char *string, const char *regex); |