Commit c3762cbd authored by David Kastrup's avatar David Kastrup
Browse files

(Fset_match_data): Allow buffer before end of list

which can happen if set-match-data is using a pre-consed list.
parent 637b9d73
2004-06-29 David Kastrup <dak@gnu.org>
* search.c (Fset_match_data): Allow buffer before end of list
which can happen if set-match-data is using a pre-consed list.
2004-06-28 Steven Tamm <tamm@Steven-Tamms-Computer.local>
 
* macterm.c (XTread_socket): Correctly set the frame position
......
......@@ -2808,9 +2808,16 @@ LIST should have been created by calling `match-data' previously. */)
search_regs.num_regs = length;
}
for (i = 0; i < length; i++)
for (i = 0;; i++)
{
marker = Fcar (list);
if (BUFFERP(marker))
{
XSETBUFFER(last_thing_searched, marker);
break;
}
if (i >= length)
break;
if (NILP (marker))
{
search_regs.start[i] = -1;
......@@ -2847,10 +2854,6 @@ LIST should have been created by calling `match-data' previously. */)
search_regs.start[i] = -1;
}
if (CONSP(list) && BUFFERP(XCAR(list))) {
XSETBUFFER(last_thing_searched, XCAR(list));
}
return Qnil;
}
......
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