[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] Changes to emacs/src/alloc.c
From: |
Richard M. Stallman |
Subject: |
[Emacs-diffs] Changes to emacs/src/alloc.c |
Date: |
Thu, 11 Jul 2002 13:44:47 -0400 |
Index: emacs/src/alloc.c
diff -c emacs/src/alloc.c:1.274 emacs/src/alloc.c:1.275
*** emacs/src/alloc.c:1.274 Thu Jul 11 10:07:54 2002
--- emacs/src/alloc.c Thu Jul 11 13:44:22 2002
***************
*** 181,186 ****
--- 181,190 ----
Lisp_Object Vpurify_flag;
+ /* Non-nil means we are handling a memory-full error. */
+
+ Lisp_Object Vmemory_full;
+
#ifndef HAVE_SHM
/* Force it into data space! */
***************
*** 224,230 ****
/* Pre-computed signal argument for use when memory is exhausted. */
! Lisp_Object memory_signal_data;
/* Maximum amount of C stack to save when a GC happens. */
--- 228,234 ----
/* Pre-computed signal argument for use when memory is exhausted. */
! Lisp_Object Vmemory_signal_data;
/* Maximum amount of C stack to save when a GC happens. */
***************
*** 469,474 ****
--- 473,480 ----
void
memory_full ()
{
+ Vmemory_full = Qt;
+
#ifndef SYSTEM_MALLOC
bytes_used_when_full = BYTES_USED;
#endif
***************
*** 483,489 ****
/* This used to call error, but if we've run out of memory, we could
get infinite recursion trying to build the string. */
while (1)
! Fsignal (Qnil, memory_signal_data);
}
--- 489,495 ----
/* This used to call error, but if we've run out of memory, we could
get infinite recursion trying to build the string. */
while (1)
! Fsignal (Qnil, Vmemory_signal_data);
}
***************
*** 503,512 ****
memory_full ();
#endif
/* This used to call error, but if we've run out of memory, we could
get infinite recursion trying to build the string. */
while (1)
! Fsignal (Qerror, memory_signal_data);
}
--- 509,520 ----
memory_full ();
#endif
+ Vmemory_full = Qt;
+
/* This used to call error, but if we've run out of memory, we could
get infinite recursion trying to build the string. */
while (1)
! Fsignal (Qnil, Vmemory_signal_data);
}
***************
*** 5541,5551 ****
Qpost_gc_hook = intern ("post-gc-hook");
staticpro (&Qpost_gc_hook);
/* We build this in advance because if we wait until we need it, we might
not be able to allocate the memory to hold it. */
! memory_signal_data
! = Fcons (Qerror, Fcons (build_string ("Memory exhausted--use M-x
save-some-buffers RET"), Qnil));
! staticpro (&memory_signal_data);
staticpro (&Qgc_cons_threshold);
Qgc_cons_threshold = intern ("gc-cons-threshold");
--- 5549,5565 ----
Qpost_gc_hook = intern ("post-gc-hook");
staticpro (&Qpost_gc_hook);
+ DEFVAR_LISP ("memory-signal-data", &Vmemory_signal_data,
+ doc: /* Precomputed `signal' argument for memory-full error.
*/);
/* We build this in advance because if we wait until we need it, we might
not be able to allocate the memory to hold it. */
! Vmemory_signal_data
! = list2 (Qerror,
! build_string ("Memory exhausted--use M-x save-some-buffers then
exit and restart Emacs"));
!
! DEFVAR_LISP ("memory-full", &Vmemory_full,
! doc: /* Non-nil means we are handling a memory-full error. */);
! Vmemory_full = Qnil;
staticpro (&Qgc_cons_threshold);
Qgc_cons_threshold = intern ("gc-cons-threshold");
- [Emacs-diffs] Changes to emacs/src/alloc.c, Juanma Barranquero, 2002/07/10
- [Emacs-diffs] Changes to emacs/src/alloc.c, Juanma Barranquero, 2002/07/11
- [Emacs-diffs] Changes to emacs/src/alloc.c,
Richard M. Stallman <=
- [Emacs-diffs] Changes to emacs/src/alloc.c, Ken Raeburn, 2002/07/14
- [Emacs-diffs] Changes to emacs/src/alloc.c, Ken Raeburn, 2002/07/16
- [Emacs-diffs] Changes to emacs/src/alloc.c, Ken Raeburn, 2002/07/16
- [Emacs-diffs] Changes to emacs/src/alloc.c, Kenichi Handa, 2002/07/26