Commit 3f57a499 authored by Richard M. Stallman's avatar Richard M. Stallman
Browse files

(search_buffer): If n is 0, just return POS.

parent 9d021db3
......@@ -610,7 +610,11 @@ search_buffer (string, pos, lim, n, RE, trt, inverse_trt)
int s1, s2;
/* Null string is found at starting position. */
if (!len)
if (len == 0)
return pos;
/* Searching 0 times means don't move. */
if (n == 0)
return pos;
if (RE)
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment