aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authorFumitoshi UKAI <ukai@debian.or.jp>2001-12-19 16:24:21 +0000
committerFumitoshi UKAI <ukai@debian.or.jp>2001-12-19 16:24:21 +0000
commit7c6a9c070a3c97057c4627379295fa7f5160acbd (patch)
treec9f9b9b537877799536d1c9062bbbf7e50f07334 /main.c
parent[#493911] too few arguments to function `longjmp (diff)
downloadw3m-7c6a9c070a3c97057c4627379295fa7f5160acbd.tar.gz
w3m-7c6a9c070a3c97057c4627379295fa7f5160acbd.zip
[w3m-dev 02672]
From: Tsutomu Okada <okada@furuno.co.jp>
Diffstat (limited to '')
-rw-r--r--main.c25
1 files changed, 9 insertions, 16 deletions
diff --git a/main.c b/main.c
index d923bb4..32ae044 100644
--- a/main.c
+++ b/main.c
@@ -1,4 +1,4 @@
-/* $Id: main.c,v 1.38 2001/12/17 16:13:40 ukai Exp $ */
+/* $Id: main.c,v 1.39 2001/12/19 16:24:21 ukai Exp $ */
#define MAINPROGRAM
#include "fm.h"
#include <signal.h>
@@ -162,26 +162,21 @@ static void
wrap_GC_warn_proc(char *msg, GC_word arg)
{
if (fmInitialized) {
- /* *INDENT-OFF* */
- static struct {
- char *msg;
- GC_word arg;
- } msg_ring[GC_WARN_KEEP_MAX] = {
- {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0},
- {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0},
- {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0},
- {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0}, {NULL, 0},
- };
- /* *INDENT-ON* */
+ /* *INDENT-OFF* */
+ static struct {
+ char *msg;
+ GC_word arg;
+ } msg_ring[GC_WARN_KEEP_MAX];
+ /* *INDENT-ON* */
static int i = 0;
static int n = 0;
static int lock = 0;
int j;
-
+
j = (i + n) % (sizeof(msg_ring) / sizeof(msg_ring[0]));
msg_ring[j].msg = msg;
msg_ring[j].arg = arg;
-
+
if (n < sizeof(msg_ring) / sizeof(msg_ring[0]))
++n;
else
@@ -4662,7 +4657,6 @@ SigAlarm(SIGNAL_ARG)
#endif
w3mFuncList[alarm_event.cmd].func();
onA();
-#ifdef USE_ALARM
if (alarm_status == AL_IMPLICIT) {
alarm_buffer = Currentbuf;
alarm_status = AL_IMPLICIT_DONE;
@@ -4675,7 +4669,6 @@ SigAlarm(SIGNAL_ARG)
signal(SIGALRM, SigAlarm);
alarm(alarm_sec);
}
-#endif
}
SIGNAL_RETURN;
}