summaryrefslogtreecommitdiff
path: root/src/search.c
diff options
context:
space:
mode:
authorDmitry Antipov <dmantipov@yandex.ru>2012-07-11 10:14:19 +0400
committerDmitry Antipov <dmantipov@yandex.ru>2012-07-11 10:14:19 +0400
commitd923b542aa2d115bb87e72e156be837cea752536 (patch)
treee2a0c475d8d1aee4c790e77765554b6926871ab6 /src/search.c
parent57054ddd444bd1702f2bcc08321d3ed3a644448e (diff)
downloademacs-d923b542aa2d115bb87e72e156be837cea752536.tar.gz
Avoid call to strlen in fast_c_string_match_ignore_case.
* search.c (fast_c_string_match_ignore_case): Change to use length argument. Adjust users accordingly. * lisp.h (fast_c_string_match_ignore_case): Adjust prototype.
Diffstat (limited to 'src/search.c')
-rw-r--r--src/search.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/search.c b/src/search.c
index de95f5a30f4..118cec4af48 100644
--- a/src/search.c
+++ b/src/search.c
@@ -490,11 +490,11 @@ fast_string_match (Lisp_Object regexp, Lisp_Object string)
We assume that STRING contains single-byte characters. */
ptrdiff_t
-fast_c_string_match_ignore_case (Lisp_Object regexp, const char *string)
+fast_c_string_match_ignore_case (Lisp_Object regexp,
+ const char *string, ptrdiff_t len)
{
ptrdiff_t val;
struct re_pattern_buffer *bufp;
- size_t len = strlen (string);
regexp = string_make_unibyte (regexp);
re_match_object = Qt;