Index: buffer.c =================================================================== RCS file: /sources/emacs/emacs/src/buffer.c,v retrieving revision 1.575 diff -r1.575 buffer.c 2184a2185,2189 > #ifdef REL_ALLOC > extern void r_alloc_prepare_to_swap_pointers P_ ((POINTER_TYPE **, > POINTER_TYPE **)); > #endif > 2222a2228,2232 > #ifdef REL_ALLOC > r_alloc_prepare_to_swap_pointers (¤t_buffer->own_text.beg, > &other_buffer->own_text.beg); > #endif > Index: ralloc.c =================================================================== RCS file: /sources/emacs/emacs/src/ralloc.c,v retrieving revision 1.69 diff -r1.69 ralloc.c 1225a1226,1248 > /* Swap relocatable data between two pointers. > This is used by buffer_swap_text. Since buffer_swap_text swaps the > whole text structure in one go, this function has been written to only > update the internal pointers back to the variables, ready for when the > swap is actually done. It must be called before the pointers are > swapped so that the state is consistent when find_bloc is called. */ > void > r_alloc_prepare_to_swap_pointers (p1, p2) > POINTER *p1, *p2; > { > bloc_ptr bloc1, bloc2; > bloc1 = find_bloc (p1); > bloc2 = find_bloc (p2); > if (bloc1 == NIL_BLOC || bloc2 == NIL_BLOC) > abort (); > > /* Swap internal pointers back to the variables. */ > bloc1->variable = p2; > bloc2->variable = p1; > > /* It would be cleaner to do the actual swap here too, but it would > complicate buffer_swap_text. */ > }