summaryrefslogtreecommitdiff
path: root/usr.bin/mg
diff options
context:
space:
mode:
authorVincent Labrecque <vincent@cvs.openbsd.org>2003-06-26 23:04:11 +0000
committerVincent Labrecque <vincent@cvs.openbsd.org>2003-06-26 23:04:11 +0000
commitfa5d3885aa4938a57d6449ed3428e000a6cfa7ed (patch)
treec5137b8c9f1d0ad2f8b961c07171901345687556 /usr.bin/mg
parent59c8cca0c7fde1839a79fcdadb3196d21ccf0361 (diff)
protos
ok deraadt
Diffstat (limited to 'usr.bin/mg')
-rw-r--r--usr.bin/mg/buffer.c4
-rw-r--r--usr.bin/mg/def.h8
-rw-r--r--usr.bin/mg/dired.c4
-rw-r--r--usr.bin/mg/main.c6
-rw-r--r--usr.bin/mg/undo.c4
5 files changed, 14 insertions, 12 deletions
diff --git a/usr.bin/mg/buffer.c b/usr.bin/mg/buffer.c
index 1d341b462ae..3e57434de45 100644
--- a/usr.bin/mg/buffer.c
+++ b/usr.bin/mg/buffer.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: buffer.c,v 1.30 2002/07/25 16:40:57 vincent Exp $ */
+/* $OpenBSD: buffer.c,v 1.31 2003/06/26 23:04:10 vincent Exp $ */
/*
* Buffer handling.
@@ -11,7 +11,7 @@
static BUFFER *makelist(void);
int
-togglereadonly(void)
+togglereadonly(int f, int n)
{
if (!(curbp->b_flag & BFREADONLY)) {
curbp->b_flag |= BFREADONLY;
diff --git a/usr.bin/mg/def.h b/usr.bin/mg/def.h
index 8b54d117f21..6e286922301 100644
--- a/usr.bin/mg/def.h
+++ b/usr.bin/mg/def.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: def.h,v 1.46 2003/05/05 11:12:07 vincent Exp $ */
+/* $OpenBSD: def.h,v 1.47 2003/06/26 23:04:10 vincent Exp $ */
#include <sys/queue.h>
@@ -21,7 +21,7 @@
#endif
#endif
-typedef int (*PF)(); /* generally useful type */
+typedef int (*PF)(int, int); /* generally useful type */
/*
* Table sizes, etc.
@@ -368,7 +368,7 @@ int delwind(int, int);
MGWIN *wpopup(void);
/* buffer.c */
-int togglereadonly(void);
+int togglereadonly(int, int);
BUFFER *bfind(const char *, int);
int poptobuffer(int, int);
int killbuffer(int, int);
@@ -579,7 +579,7 @@ int cntnonmatchlines(int, int);
/* undo.c X */
void free_undo_record(struct undo_rec *);
-int undo_dump(void);
+int undo_dump(int, int);
int undo_enable(int);
int undo_add_custom(int, int, LINE *, int, void *, int);
int undo_add_boundary(void);
diff --git a/usr.bin/mg/dired.c b/usr.bin/mg/dired.c
index cbcfbc5e5e4..f0d18d4d63f 100644
--- a/usr.bin/mg/dired.c
+++ b/usr.bin/mg/dired.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dired.c,v 1.10 2002/03/11 13:02:56 vincent Exp $ */
+/* $OpenBSD: dired.c,v 1.11 2003/06/26 23:04:10 vincent Exp $ */
/* dired module for mg 2a */
/* by Robert A. Larson */
@@ -8,6 +8,8 @@
#ifndef NO_DIRED
+int d_findfile(int, int);
+
static PF dired_pf[] = {
d_findfile,
};
diff --git a/usr.bin/mg/main.c b/usr.bin/mg/main.c
index ec92f5ec22a..9cc3ce3853d 100644
--- a/usr.bin/mg/main.c
+++ b/usr.bin/mg/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.24 2003/05/05 11:12:07 vincent Exp $ */
+/* $OpenBSD: main.c,v 1.25 2003/06/26 23:04:10 vincent Exp $ */
/*
* Mainline.
@@ -108,7 +108,7 @@ notnum:
(void)showbuffer(curbp, curwp, 0);
(void)readin(cp);
if (init_fcn_name)
- init_fcn();
+ init_fcn(0, 1);
}
}
argc--;
@@ -178,7 +178,7 @@ edinit(PF init_fcn)
wp->w_flag = WFMODE | WFHARD; /* Full. */
if (init_fcn)
- init_fcn();
+ init_fcn(0, 1);
}
/*
diff --git a/usr.bin/mg/undo.c b/usr.bin/mg/undo.c
index c25d351608c..5d10f21f19b 100644
--- a/usr.bin/mg/undo.c
+++ b/usr.bin/mg/undo.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: undo.c,v 1.17 2003/06/01 15:53:34 deraadt Exp $ */
+/* $OpenBSD: undo.c,v 1.18 2003/06/26 23:04:10 vincent Exp $ */
/*
* Copyright (c) 2002 Vincent Labrecque
* All rights reserved.
@@ -359,7 +359,7 @@ undo_add_change(LINE *lp, int offset, int size)
* Show the undo records for the current buffer in a new buffer.
*/
int
-undo_dump(void)
+undo_dump(int f, int n)
{
struct undo_rec *rec;
BUFFER *bp;