changeset 23579:3d1bb0100afb

(Fbase64_encode_region): Use SET_PT_BOTH instead of SET_PT when we have both char and byte position. Fix type clashes.
author Andreas Schwab <schwab@suse.de>
date Fri, 30 Oct 1998 10:20:25 +0000
parents a4b29402f761
children 4ade2b248148
files src/fns.c
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/fns.c	Fri Oct 30 10:14:50 1998 +0000
+++ b/src/fns.c	Fri Oct 30 10:20:25 1998 +0000
@@ -2839,7 +2839,7 @@
 
   /* Now we have encoded the region, so we insert the new contents
      and delete the old.  (Insert first in order to preserve markers.)  */
-  SET_PT (beg);
+  SET_PT_BOTH (XFASTINT (beg), ibeg);
   insert (encoded, encoded_length);
   del_range_byte (ibeg + encoded_length, iend + encoded_length, 1);
 
@@ -2847,8 +2847,8 @@
      move to the beginning of the region.  */
   if (old_pos >= XFASTINT (end))
     old_pos += encoded_length - (XFASTINT (end) - XFASTINT (beg));
-  else if (old_pos > beg)
-    old_pos = beg;
+  else if (old_pos > XFASTINT (beg))
+    old_pos = XFASTINT (beg);
   SET_PT (old_pos);
 
   /* We return the length of the encoded text. */