Commits

Anonymous committed 0801516

Import from CVS: tag r21-2-26

Comments (0)

Files changed (24)

+to 21.2.26 "Millenium"
+-- Fix unpredictable results, perhaps even crashes, if using the
+   `return from debugger feature' and errors in `eval' or `funcall'.
+-- fix for Tab widgets causing X errors in XMapWindow().
+
 to 21.2.25 "Hephaestus"
 -- the LATEST.IS.* file has been renamed to LATEST-IS-*.
 -- the CVS tag to checkout the latest tarball is `r21-2-latest-beta'.
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.

lib-src/ChangeLog

+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
+1999-12-28  Andy Piper  <andy@xemacs.org>
+
+	* wid-edit.el (widget-push-button-value-create): The gui cache
+	does not agree with native widgets which can only be displayed
+	once per window. The reasons for caching are diminished now that
+	we don't hog resources when creating buttons.
+	(widget-push-button-cache) deleted.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
   :group 'widgets
   :type 'boolean)
 
-;; Cache already created GUI objects.
-(defvar widget-push-button-cache nil)
-
 (defcustom widget-push-button-prefix "["
   "String used as prefix for buttons."
   :type 'string
 	 (tag-glyph (widget-get widget :tag-glyph))
 	 (text (concat widget-push-button-prefix
 		       tag widget-push-button-suffix))
-	 (gui-glyphs (lax-plist-get widget-push-button-cache tag)))
+	 gui)
     (cond (tag-glyph
 	   (widget-glyph-insert widget text tag-glyph))
 	  ;; We must check for console-on-window-system-p here,
 	  ;; components for colors, and they are not known on TTYs).
 	  ((and widget-push-button-gui
 		(console-on-window-system-p))
-	   (unless gui-glyphs
-	     (let* ((gui-button-shadow-thickness 1)
-		    (gui (make-glyph 
-			  (make-gui-button tag 'widget-gui-action widget))))
-	       (setq gui-glyphs gui)
-	       (laxputf widget-push-button-cache tag gui-glyphs)))
-	   (widget-glyph-insert-glyph widget gui-glyphs))
+	   (let* ((gui-button-shadow-thickness 1))
+	     (setq gui (make-glyph 
+			(make-gui-button tag 'widget-gui-action widget))))
+	   (widget-glyph-insert-glyph widget gui))
 	  (t
 	   (insert text)))))
 
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
+1999-12-29  Andy Piper  <andy@xemacs.org>
+
+	* xlwtabs.c (TabsHighlight): use displayChildren for highlighting
+	not num_children.
+	(TabsPage): ditto.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
 	Widget		newtop = NULL;
 	Widget		*childP ;
 	int		idx ;
-	int		nc = tw->composite.num_children ;
+	int		nc = tw->tabs.displayChildren ;
 
 	if( nc <= 0 )
 	  return ;
 	Widget		newhl = NULL;
 	Widget		*childP ;
 	int		idx ;
-	int		nc = tw->composite.num_children ;
+	int		nc = tw->tabs.displayChildren ;
 
 	if( nc <= 0 )
 	  return ;
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
+1999-12-26  Karl M. Hegbloom  <karlheg@inetarena.com>
+
+	* internals/internals.texi (garbage_collect_1): Xemacs -> XEmacs
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.

man/internals/internals.texi

 manually. That is done by the function @code{mark_profiling_info}
 @end itemize
 @item
-Hash tables in Xemacs belong to a kind of special objects that
+Hash tables in XEmacs belong to a kind of special objects that
 make use of a concept often called 'weak pointers'.
 To make a long story short, these kind of pointers are not followed
 during the estimation of the live objects during garbage collection.
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
+1999-12-31  Andy Piper  <andy@xemacs.org>
+
+	* glyphs-x.c (x_widget_instantiate): Avoid X errors calling
+	XMapWindow() on a NULL pointer X window.
+
+1999-12-31  Martin Buchholz  <martin@xemacs.org>
+
+	* data.c (indirect_function): Use signal_void_function_error().
+
+	* lisp.h: Modify prototypes for signal_*().  Add SUBR_FUNCTION macro.
+
+	* eval.c (PRIMITIVE_FUNCALL): Optimize.
+	(signal_void_function_error): return result of Fsignal().
+	(signal_invalid_function_error): return result of Fsignal().
+	(signal_wrong_number_of_arguments_error): return result of Fsignal().
+	(signal_malformed_list_error): Add DOESNT_RETURN.
+	(signal_malformed_property_list_error): Add DOESNT_RETURN.
+	(signal_circular_list_error): Add DOESNT_RETURN.
+	(signal_circular_property_list_error): Add DOESNT_RETURN.
+	(Feval): Use returned results of signal_*().  Avoids a crash!
+	(Ffuncall): Use returned results of signal_*(). Avoids the crash:
+	  (setq debug-on-error t) (funcall 'foo) kbd{r42} kbd{RET}
+	- Only check for fun_nargs < subr_min_args if fun_nargs != max_args.
+	(function_argcount): Use signal_invalid_function_error().
+	(funcall_lambda): Use signal_wrong_number_of_arguments_error().
+	Use signal_invalid_function_error().
+
+1999-12-28  Andy Piper  <andy@xemacs.org>
+
+	* debug.c: rename debug_loop elements to X_ to avoid name clashes.
+
+	* menubar-x.c (menu_item_descriptor_to_widget_value_1): strdup
+	string_chars.
+	(menu_item_descriptor_to_widget_value_1): strdup name.
+	(pre_activate_callback): strdup name.
+
+	* scrollbar-x.c (scrollbar_instance_to_widget_value): strdup name.
+	(x_update_scrollbar_instance_status): use free_widget_value_tree.
+
+	* dialog-x.c (maybe_run_dbox_text_callback): strdup name.  use
+	free_widget_value_tree.
+	(dbox_descriptor_to_widget_value): ditto.
+
+	* gui-x.c (widget_value_unwind): use free_widget_value_tree.
+	(gui_items_to_widget_values_1): ditto.
+	(gui_items_to_widget_values): ditto.
+	(free_popup_widget_value_tree): free name.
+
+1999-12-27  Andy Piper  <andy@xemacs.org>
+
+	* nt.c (fstat): use get_osfhandle rather than the handle
+	directly. From Fabrice Popineau.
+
+	* process-nt.c (nt_open_network_stream): take types into account
+	when warning. From Fabrice Popineau.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
     }
 
   if (errorp && UNBOUNDP (hare))
-    signal_void_function_error (object);
+    return signal_void_function_error (object);
 
   return hare;
 }
 
 enum debug_loop
 {
-  ADD,
-  DELETE,
-  LIST,
-  ACTIVE,
-  INIT,
-  VALIDATE,
-  TYPE,
-  SETTYPE
+  X_ADD,
+  X_DELETE,
+  X_LIST,
+  X_ACTIVE,
+  X_INIT,
+  X_VALIDATE,
+  X_TYPE,
+  X_SETTYPE
 };
 
 static Lisp_Object
 xemacs_debug_loop (enum debug_loop op, Lisp_Object class, Lisp_Object type)
 {
-  int flag = (op == ADD) ? 1 : 0;
+  int flag = (op == X_ADD) ? 1 : 0;
   Lisp_Object retval = Qnil;
 
 #define FROB(item)							\
-  if (op == LIST || op == ACTIVE || op == INIT || EQ (class, Q##item))	\
+  if (op == X_LIST || op == X_ACTIVE || op == X_INIT || EQ (class, Q##item))	\
     {									\
-      if (op == ADD || op == DELETE || op == INIT)			\
+      if (op == X_ADD || op == X_DELETE || op == X_INIT)			\
 	active_debug_classes.item = flag;				\
-      else if (op == LIST						\
-	       || (op == ACTIVE && active_debug_classes.item))		\
+      else if (op == X_LIST						\
+	       || (op == X_ACTIVE && active_debug_classes.item))		\
 	retval = Fcons (Q##item, retval);				\
-      else if (op == VALIDATE)						\
+      else if (op == X_VALIDATE)						\
 	return Qt;							\
-      else if (op == SETTYPE)						\
+      else if (op == X_SETTYPE)						\
         active_debug_classes.types_of_##item = XINT (type);		\
-      else if (op == TYPE)						\
+      else if (op == X_TYPE)						\
         retval = make_int (active_debug_classes.types_of_##item);	\
-      if (op == INIT) active_debug_classes.types_of_##item = VALBITS;	\
+      if (op == X_INIT) active_debug_classes.types_of_##item = VALBITS;	\
     }
 
   FROB (redisplay);
 */
        (class))
 {
-  if (NILP (xemacs_debug_loop (VALIDATE, class, Qnil)))
+  if (NILP (xemacs_debug_loop (X_VALIDATE, class, Qnil)))
     error ("No such debug class exists");
   else
-    xemacs_debug_loop (ADD, class, Qnil);
+    xemacs_debug_loop (X_ADD, class, Qnil);
 
-  return (xemacs_debug_loop (ACTIVE, Qnil, Qnil));
+  return (xemacs_debug_loop (X_ACTIVE, Qnil, Qnil));
 }
 
 DEFUN ("delete-debug-class-to-check", Fdelete_debug_class_to_check, 1, 1, 0, /*
 */
        (class))
 {
-  if (NILP (xemacs_debug_loop (VALIDATE, class, Qnil)))
+  if (NILP (xemacs_debug_loop (X_VALIDATE, class, Qnil)))
     error ("No such debug class exists");
   else
-    xemacs_debug_loop (DELETE, class, Qnil);
+    xemacs_debug_loop (X_DELETE, class, Qnil);
 
-  return (xemacs_debug_loop (ACTIVE, Qnil, Qnil));
+  return (xemacs_debug_loop (X_ACTIVE, Qnil, Qnil));
 }
 
 DEFUN ("debug-classes-being-checked", Fdebug_classes_being_checked, 0, 0, 0, /*
 */
        ())
 {
-  return (xemacs_debug_loop (ACTIVE, Qnil, Qnil));
+  return (xemacs_debug_loop (X_ACTIVE, Qnil, Qnil));
 }
 
 DEFUN ("debug-classes-list", Fdebug_classes_list, 0, 0, 0, /*
 */
        ())
 {
-  return (xemacs_debug_loop (LIST, Qnil, Qnil));
+  return (xemacs_debug_loop (X_LIST, Qnil, Qnil));
 }
 
 DEFUN ("set-debug-classes-to-check", Fset_debug_classes_to_check, 1, 1, 0, /*
      valid, reject the entire list without doing anything. */
   LIST_LOOP (rest, classes )
     {
-      if (NILP (xemacs_debug_loop (VALIDATE, XCAR (rest), Qnil)))
+      if (NILP (xemacs_debug_loop (X_VALIDATE, XCAR (rest), Qnil)))
 	error ("Invalid object in class list");
     }
 
   LIST_LOOP (rest, classes)
     Fadd_debug_class_to_check (XCAR (rest));
 
-  return (xemacs_debug_loop (ACTIVE, Qnil, Qnil));
+  return (xemacs_debug_loop (X_ACTIVE, Qnil, Qnil));
 }
 
 DEFUN ("set-debug-class-types-to-check", Fset_debug_class_types_to_check, 2, 2, 0, /*
        (class, type))
 {
   CHECK_INT (type);
-  if (NILP (xemacs_debug_loop (VALIDATE, class, Qnil)))
+  if (NILP (xemacs_debug_loop (X_VALIDATE, class, Qnil)))
     error ("Invalid debug class");
 
-  xemacs_debug_loop (SETTYPE, class, type);
+  xemacs_debug_loop (X_SETTYPE, class, type);
 
-  return (xemacs_debug_loop (TYPE, class, Qnil));
+  return (xemacs_debug_loop (X_TYPE, class, Qnil));
 }
 
 DEFUN ("debug-types-being-checked", Fdebug_types_being_checked, 1, 1, 0, /*
 */
        (class))
 {
-  if (NILP (xemacs_debug_loop (VALIDATE, class, Qnil)))
+  if (NILP (xemacs_debug_loop (X_VALIDATE, class, Qnil)))
     error ("Invalid debug class");
 
-  return (xemacs_debug_loop (TYPE, class, Qnil));
+  return (xemacs_debug_loop (X_TYPE, class, Qnil));
 }
 
 void
      the flags should be set here.
      All functions called by this function are "allowed" according
      to emacs.c. */
-  xemacs_debug_loop (INIT, Qnil, Qnil);
+  xemacs_debug_loop (X_INIT, Qnil, Qnil);
 }
 
 void
   widget_value *wv;
   int got_some;
   wv = xmalloc_widget_value ();
-  wv->name = (char *) "value";
+  wv->name = xstrdup ("value");
   got_some = lw_get_some_values (id, wv);
   if (got_some)
     {
 	  void *tmp = LISP_TO_VOID (list2 (text_field_callback,
                                            build_string (text_field_value)));
 	  popup_selection_callback (0, id, (XtPointer) tmp);
-	  xfree (text_field_value);
 	}
     }
-  free_widget_value (wv);
+  /* This code tried to optimize, newing/freeing. This is generally
+     unsafe so we will alwats strdup and always use
+     free_widget_value_tree. */
+  free_widget_value_tree (wv);
 }
 
 static void
 
   wv_closure = make_opaque_ptr (kids);
   record_unwind_protect (widget_value_unwind, wv_closure);
-  prev->name = (char *) "message";
+  prev->name = xstrdup ("message");
   prev->value = xstrdup (name);
   prev->enabled = 1;
 
       gui_item = gui_parse_item_keywords (button);
       if (!button_item_to_widget_value (gui_item, wv, allow_text_p, 1))
 	{
-	  free_widget_value (wv);
+	  free_widget_value_tree (wv);
 	  continue;
 	}
 
       else			/* it's a button */
 	{
 	  allow_text_p = 0;	 /* only allow text field at the front */
-	  wv->value = xstrdup (wv->name);	/* what a mess... */
-	  wv->name = (char *) button_names [n];
+	  if (wv->value)	xfree (wv->value);
+	  wv->value = wv->name;	/* what a mess... */
+	  wv->name = xstrdup (button_names [n]);
 
 	  if (partition_seen)
 	    rbuttons++;
     widget_value *dbox;
     sprintf (tmp_dbox_name, "%c%dBR%d", type, lbuttons + rbuttons, rbuttons);
     dbox = xmalloc_widget_value ();
-    dbox->name = tmp_dbox_name;
+    dbox->name = xstrdup (tmp_dbox_name);
     dbox->contents = kids;
 
     /* No more need to free the half-filled-in structures. */
   Lisp_Object *PF_av = (av);					\
   switch (ac)							\
     {								\
-    default: abort();						\
-    case 0: rv = PRIMITIVE_FUNCALL_1(PF_fn, PF_av, 0); break;	\
+    default:rv = PRIMITIVE_FUNCALL_1(PF_fn, PF_av, 0); break;	\
     case 1: rv = PRIMITIVE_FUNCALL_1(PF_fn, PF_av, 1); break;	\
     case 2: rv = PRIMITIVE_FUNCALL_1(PF_fn, PF_av, 2); break;	\
     case 3: rv = PRIMITIVE_FUNCALL_1(PF_fn, PF_av, 3); break;	\
 
 
 /* Used in core lisp functions for efficiency */
-void
+Lisp_Object
 signal_void_function_error (Lisp_Object function)
 {
-  Fsignal (Qvoid_function, list1 (function));
+  return Fsignal (Qvoid_function, list1 (function));
 }
 
-static void
+Lisp_Object
 signal_invalid_function_error (Lisp_Object function)
 {
-  Fsignal (Qinvalid_function, list1 (function));
+  return Fsignal (Qinvalid_function, list1 (function));
 }
 
-static void
+Lisp_Object
 signal_wrong_number_of_arguments_error (Lisp_Object function, int nargs)
 {
-  Fsignal (Qwrong_number_of_arguments, list2 (function, make_int (nargs)));
+  return Fsignal (Qwrong_number_of_arguments,
+		  list2 (function, make_int (nargs)));
 }
 
 /* Used in list traversal macros for efficiency. */
-void
+DOESNT_RETURN
 signal_malformed_list_error (Lisp_Object list)
 {
-  Fsignal (Qmalformed_list, list1 (list));
+  signal_error (Qmalformed_list, list1 (list));
 }
 
-void
+DOESNT_RETURN
 signal_malformed_property_list_error (Lisp_Object list)
 {
-  Fsignal (Qmalformed_property_list, list1 (list));
+  signal_error (Qmalformed_property_list, list1 (list));
 }
 
-void
+DOESNT_RETURN
 signal_circular_list_error (Lisp_Object list)
 {
-  Fsignal (Qcircular_list, list1 (list));
+  signal_error (Qcircular_list, list1 (list));
 }
 
-void
+DOESNT_RETURN
 signal_circular_property_list_error (Lisp_Object list)
 {
-  Fsignal (Qcircular_property_list, list1 (list));
+  signal_error (Qcircular_property_list, list1 (list));
 }
 
 /************************************************************************/
       else
 	{
 	wrong_number_of_arguments:
-	  signal_wrong_number_of_arguments_error (fun, nargs);
+	  val = signal_wrong_number_of_arguments_error (fun, nargs);
 	}
     }
   else if (COMPILED_FUNCTIONP (fun))
   else /* ! (SUBRP (fun) || COMPILED_FUNCTIONP (fun) || CONSP (fun)) */
     {
     invalid_function:
-      signal_invalid_function_error (fun);
+      val = signal_invalid_function_error (fun);
     }
 
   lisp_eval_depth--;
       int max_args = subr->max_args;
       Lisp_Object spacious_args[SUBR_MAX_ARGS];
 
-      if (fun_nargs < subr->min_args)
-	goto wrong_number_of_arguments;
-
       if (fun_nargs == max_args) /* Optimize for the common case */
 	{
 	funcall_subr:
 	  FUNCALL_SUBR (val, subr, fun_args, max_args);
 	}
+      else if (fun_nargs < subr->min_args)
+	{
+	  goto wrong_number_of_arguments;
+	}
       else if (fun_nargs < max_args)
 	{
 	  Lisp_Object *p = spacious_args;
 	}
       else if (max_args == MANY)
 	{
-	  val = ((Lisp_Object (*) (int, Lisp_Object *)) subr_function (subr))
-	    (fun_nargs, fun_args);
+	  val = SUBR_FUNCTION (subr, MANY) (fun_nargs, fun_args);
 	}
       else if (max_args == UNEVALLED) /* Can't funcall a special form */
 	{
       else
 	{
 	wrong_number_of_arguments:
-	  signal_wrong_number_of_arguments_error (fun, fun_nargs);
+	  val = signal_wrong_number_of_arguments_error (fun, fun_nargs);
 	}
     }
   else if (COMPILED_FUNCTIONP (fun))
     }
   else if (UNBOUNDP (fun))
     {
-      signal_void_function_error (args[0]);
+      val = signal_void_function_error (args[0]);
     }
   else
     {
     invalid_function:
-      signal_invalid_function_error (fun);
+      val = signal_invalid_function_error (fun);
     }
 
   lisp_eval_depth--;
   else
     {
     invalid_function:
-      return Fsignal (Qinvalid_function, list1 (function));
+      return signal_invalid_function_error (function);
     }
 
   {
   return unbind_to (speccount, Fprogn (body));
 
  wrong_number_of_arguments:
-  return Fsignal (Qwrong_number_of_arguments, list2 (fun, make_int (nargs)));
+  return signal_wrong_number_of_arguments_error (fun, nargs);
 
  invalid_function:
-  return Fsignal (Qinvalid_function, list1 (fun));
+  return signal_invalid_function_error (fun);
 }
 
 
   XtSetArg (al [ac], XtNy, &IMAGE_INSTANCE_X_WIDGET_YOFFSET (ii)); ac++;
   XtGetValues (FRAME_X_TEXT_WIDGET (f), al, ac);
 
-  XtMapWidget (wid);
+  XtSetMappedWhenManaged (wid, TRUE);
 
   free_widget_value_tree (wv);
 }
   widget_value *wv = (widget_value *) get_opaque_ptr (closure);
   free_opaque_ptr (closure);
   if (wv)
-    free_widget_value (wv);
+    free_widget_value_tree (wv);
   return Qnil;
 }
 
   if (! wv) return;
   if (wv->key) xfree (wv->key);
   if (wv->value) xfree (wv->value);
+  if (wv->name) xfree (wv->name);
 
   wv->name = wv->value = wv->key = (char *) 0xDEADBEEF;
 
 	prev->next = wv;
       if (!button_item_to_widget_value (items, wv, 0, 1))
 	{
-	  free_widget_value (wv);
+	  free_widget_value_tree (wv);
 	  if (parent)
 	    parent->contents = 0;
 	  else 
   control = control->contents;
   tmp->next = 0;
   tmp->contents = 0;
-  free_widget_value (tmp);
+  free_widget_value_tree (tmp);
 
   /* No more need to free the half-filled-in structures. */
   set_opaque_ptr (wv_closure, 0);
 #define CHECK_TRUE_LIST(list) do {			\
   Lisp_Object CTL_list = (list);			\
   Lisp_Object CTL_hare, CTL_tortoise;			\
-  EMACS_INT CTL_len;						\
+  EMACS_INT CTL_len;					\
 							\
   for (CTL_hare = CTL_tortoise = CTL_list, CTL_len = 0;	\
        CONSP (CTL_hare);				\
 #define CHECK_SUBR(x) CHECK_RECORD (x, subr)
 #define CONCHECK_SUBR(x) CONCHECK_RECORD (x, subr)
 
-#define subr_function(subr) (subr)->subr_fn
-#define subr_name(subr) (subr)->name
+#define subr_function(subr) ((subr)->subr_fn)
+#define SUBR_FUNCTION(subr,max_args) \
+  ((Lisp_Object (*) (EXFUN_##max_args)) (subr)->subr_fn)
+#define subr_name(subr) ((subr)->name)
 
 /*********** marker ***********/
 
 Lisp_Object maybe_signal_simple_continuable_error_2 (CONST char *, Lisp_Object,
 						     Lisp_Object, Lisp_Object,
 						     Error_behavior);
-void signal_malformed_list_error (Lisp_Object);
-void signal_malformed_property_list_error (Lisp_Object);
-void signal_circular_list_error (Lisp_Object);
-void signal_circular_property_list_error (Lisp_Object);
-void signal_void_function_error (Lisp_Object);
+DECLARE_DOESNT_RETURN (signal_malformed_list_error (Lisp_Object));
+DECLARE_DOESNT_RETURN (signal_malformed_property_list_error (Lisp_Object));
+DECLARE_DOESNT_RETURN (signal_circular_list_error (Lisp_Object));
+DECLARE_DOESNT_RETURN (signal_circular_property_list_error (Lisp_Object));
+
+Lisp_Object signal_void_function_error (Lisp_Object);
+Lisp_Object signal_invalid_function_error (Lisp_Object);
+Lisp_Object signal_wrong_number_of_arguments_error (Lisp_Object, int);
+
 Lisp_Object run_hook_with_args_in_buffer (struct buffer *, int, Lisp_Object *,
 					  enum run_hooks_condition);
 Lisp_Object run_hook_with_args (int, Lisp_Object *, enum run_hooks_condition);
 	}
       else
 	{
-	  wv->name = string_chars;
+	  wv->name = xstrdup (string_chars);
 	  wv->enabled = 1;
 	  /* dverna Dec. 98: command_builder_operate_menu_accelerator will
 	     manipulate the accel as a Lisp_Object if the widget has a name.
 	  wv->type = CASCADE_TYPE;
 	  wv->enabled = 1;
 	  wv->name = (char *) XSTRING_DATA (LISP_GETTEXT (XCAR (desc)));
+	  wv->name = xstrdup (wv->name);
 
 	  accel = gui_name_accelerator (LISP_GETTEXT (XCAR (desc)));
 	  wv->accel = LISP_TO_VOID (accel);
 		  incr_wv->type = INCREMENTAL_TYPE;
 		  incr_wv->enabled = 1;
 		  incr_wv->name = wv->name;
+		  incr_wv->name = xstrdup (wv->name);
 		  /* This is automatically GC protected through
 		     the call to lw_map_widget_values(); no need
 		     to worry. */
 	      widget_value *title_wv = xmalloc_widget_value ();
 	      widget_value *sep_wv = xmalloc_widget_value ();
 	      title_wv->type = TEXT_TYPE;
-	      title_wv->name = wv->name;
+	      title_wv->name = xstrdup (wv->name);
 	      title_wv->enabled = 1;
 	      title_wv->next = sep_wv;
 	      sep_wv->type = SEPARATOR_TYPE;
 	      widget_value *dummy;
 	      /* Add a fake entry so the menus show up */
 	      wv->contents = dummy = xmalloc_widget_value ();
-	      dummy->name = "(inactive)";
+	      dummy->name = xstrdup ("(inactive)");
 	      dummy->accel = LISP_TO_VOID (Qnil);
 	      dummy->enabled = 0;
 	      dummy->selected = 0;
 	}
       else if (menubar_root_p)
 	{
-	  wv->name = (char *) "menubar";
+	  wv->name = xstrdup ("menubar");
 	  wv->type = CASCADE_TYPE; /* Well, nothing else seems to fit and
 				      this is ignored anyway...  */
 	}
 	  wv->accel = LISP_TO_VOID (Qnil);
 	  wv->contents = xmalloc_widget_value ();
 	  wv->contents->type = TEXT_TYPE;
-	  wv->contents->name = (char *) "No menu";
+	  wv->contents->name = xstrdup ("No menu");
 	  wv->contents->next = NULL;
 	  wv->contents->accel = LISP_TO_VOID (Qnil);
 	}
   buffer->st_ctime = 0;
   buffer->st_mtime = 0;
   buffer->st_nlink = 0;
-  ret = GetFileInformationByHandle((HANDLE) handle, &lpFileInfo);
+  ret = GetFileInformationByHandle((HANDLE) _get_osfhandle(handle), &lpFileInfo);
   if (!ret)
     {
       return -1;
 
  connect_failed:  
   closesocket (s);
-  warn_when_safe(Qstream, Qwarning,
-		 "failure to open network stream to host \"%s\" for service \"%s\"",
-		 XSTRING_DATA (host),
-		 XSTRING_DATA (service));
+  if (INTP (service)) {
+    warn_when_safe(Qstream, Qwarning,
+		   "failure to open network stream to host \"%s\" for service \"%d\"",
+		   XSTRING_DATA (host),
+		   (unsigned short) XINT (service));
+  }
+  else {
+    warn_when_safe(Qstream, Qwarning,
+		   "failure to open network stream to host \"%s\" for service \"%s\"",
+		   XSTRING_DATA (host),
+		   XSTRING_DATA (service));
+  }
   report_file_error ("connection failed", list2 (host, name));
 }
 

src/scrollbar-x.c

   wv->scrollbar_data = xnew (scrollbar_values);
 
   wv->name = SCROLLBAR_X_NAME (instance);
+  wv->name = xstrdup (wv->name);
   wv->value = 0;
   wv->key = 0;
   wv->enabled = instance->scrollbar_is_active;
 	}
 
       if (!wv->scrollbar_data) abort ();
-      xfree (wv->scrollbar_data);
-      wv->scrollbar_data = 0;
-      free_widget_value (wv);
+      free_widget_value_tree (wv);
     }
   else if (managed)
     {
+1999-12-31  Martin Buchholz <martin@xemacs.org>
+
+	* XEmacs 21.2.26 is released.
+
 1999-12-24  Martin Buchholz <martin@xemacs.org>
 
 	* XEmacs 21.2.25 is released.
 emacs_is_beta=t
 emacs_major_version=21
 emacs_minor_version=2
-emacs_beta_version=25
-xemacs_codename="Hephaestus"
+emacs_beta_version=26
+xemacs_codename="Millenium"
 infodock_major_version=4
 infodock_minor_version=0
 infodock_build_version=8