changeset 78824:c33d8980019c

(Fplist_put): Preserve uneven tail data.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Tue, 18 Sep 2007 01:45:39 +0000
parents 3507e8974e13
children 6ba709e4adda
files src/ChangeLog src/fns.c
diffstat 2 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/ChangeLog	Tue Sep 18 01:29:04 2007 +0000
+++ b/src/ChangeLog	Tue Sep 18 01:45:39 2007 +0000
@@ -1,3 +1,7 @@
+2007-09-18  Stefan Monnier  <monnier@iro.umontreal.ca>
+
+	* fns.c (Fplist_put): Preserve uneven tail data.
+
 2007-09-16  Jan Dj,Ad(Brv  <jan.h.d@swipnet.se>
 
 	* gtkutil.c (xg_get_image_for_pixmap): Always create a GdkPixbuf
--- a/src/fns.c	Tue Sep 18 01:29:04 2007 +0000
+++ b/src/fns.c	Tue Sep 18 01:45:39 2007 +0000
@@ -2060,7 +2060,7 @@
       prev = tail;
       QUIT;
     }
-  newcell = Fcons (prop, Fcons (val, Qnil));
+  newcell = Fcons (prop, Fcons (val, NILP (prev) ? plist : XCDR (XCDR (prev))));
   if (NILP (prev))
     return newcell;
   else