summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorceastha <none@none>2005-08-18 15:40:59 -0700
committerceastha <none@none>2005-08-18 15:40:59 -0700
commitb7d62af5b42f0da2eb668e8d33d24d2f4fdd98a8 (patch)
tree365a354cfe8236488955cf206e4f43644ca03ea0
parentd6555420322a42c16b93414c29a62f8e841abc7b (diff)
downloadillumos-joyent-b7d62af5b42f0da2eb668e8d33d24d2f4fdd98a8.tar.gz
6268906 ucbcmd/plot and gcc don't get along
6271073 gcc and cmd/fmt don't get along 6271996 gcc and cmd/mail don't get along 6272084 gcc and cmd/pax don't get along 6273914 gcc and cmd/tar don't get along --HG-- rename : usr/src/cmd/fmt/head.c => deleted_files/usr/src/cmd/fmt/head.c rename : usr/src/cmd/mail/maid.c => deleted_files/usr/src/cmd/mail/maid.c
-rw-r--r--deleted_files/usr/src/cmd/fmt/head.c (renamed from usr/src/cmd/fmt/head.c)0
-rw-r--r--deleted_files/usr/src/cmd/mail/maid.c (renamed from usr/src/cmd/mail/maid.c)0
-rw-r--r--usr/src/cmd/fmt/fmt.c93
-rwxr-xr-xusr/src/cmd/fmt/inc.flg30
-rw-r--r--usr/src/cmd/mail/Makefile4
-rw-r--r--usr/src/cmd/mail/add_recip.c20
-rw-r--r--usr/src/cmd/mail/copylet.c18
-rw-r--r--usr/src/cmd/mail/getcomment.c17
-rw-r--r--usr/src/cmd/mail/gethead.c33
-rw-r--r--usr/src/cmd/mail/islocal.c10
-rw-r--r--usr/src/cmd/mail/istext.c16
-rw-r--r--usr/src/cmd/mail/mail.h15
-rw-r--r--usr/src/cmd/mail/main.c14
-rw-r--r--usr/src/cmd/mail/parse.c17
-rw-r--r--usr/src/cmd/mail/pckaffspot.c13
-rw-r--r--usr/src/cmd/mail/pckrcvspot.c13
-rw-r--r--usr/src/cmd/mail/pipletr.c16
-rw-r--r--usr/src/cmd/mail/printhdr.c22
-rw-r--r--usr/src/cmd/mail/sel_disp.c14
-rw-r--r--usr/src/cmd/mail/sendlist.c22
-rw-r--r--usr/src/cmd/tar/tar.c4
-rw-r--r--usr/src/ucbcmd/plot/atoplot.c49
-rw-r--r--usr/src/ucbcmd/plot/crtdriver.c44
-rw-r--r--usr/src/ucbcmd/plot/crtplot.c195
-rw-r--r--usr/src/ucbcmd/plot/debug.c44
-rw-r--r--usr/src/ucbcmd/plot/driver.c43
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/aed.h22
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/close.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/erase.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/line.c38
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/open.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/aed/subr.c47
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/circle.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/close.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/cont.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/dot.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/erase.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/label.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/line.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/linemod.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/move.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/open.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/point.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/bitgraph/space.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/circle.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/close.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/line.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/open.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/dumb/subr.c29
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/close.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/erase.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/line.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/open.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/gigi/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/arc.c22
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/close.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/erase.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/line.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/open.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp2648/subr.c26
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/close.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/erase.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/line.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/open.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/hp7221/subr.c26
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/arc.c34
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/charset.c15
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/close.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/cont.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/label.c24
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/line.c30
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/linemod.c22
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/move.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/open.c24
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/scale.c20
-rw-r--r--usr/src/ucbcmd/plot/libplot/imagen/space.c20
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/arc.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/circle.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/close.c24
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/cont.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/dot.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/label.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/line.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/linmod.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/move.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/open.c23
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/point.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/putsi.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/plot/space.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/close.c26
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/label.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/line.c31
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/linmod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/open.c25
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/point.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/space.c20
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300/subr.c61
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/arc.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/box.c16
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/close.c26
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/label.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/line.c31
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/linmod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/open.c25
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/point.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/space.c21
-rw-r--r--usr/src/ucbcmd/plot/libplot/t300s/subr.c78
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/arc.c28
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/box.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/circle.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/close.c24
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/dot.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/erase.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/label.c20
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/line.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/linemod.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/move.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/open.c23
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/point.c19
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/space.c20
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4013/subr.c27
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/arc.c33
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/box.c16
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/circle.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/close.c23
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/dot.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/erase.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/label.c21
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/line.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/linemod.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/move.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/open.c21
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/point.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t4014/subr.c25
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/arc.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/box.c16
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/circle.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/close.c23
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/dot.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/erase.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/label.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/line.c28
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/linmod.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/move.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/open.c48
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/point.c17
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/space.c18
-rw-r--r--usr/src/ucbcmd/plot/libplot/t450/subr.c60
-rw-r--r--usr/src/ucbcmd/plot/plottoa.c103
-rw-r--r--usr/src/ucbcmd/plot/vplot.c75
218 files changed, 2520 insertions, 2291 deletions
diff --git a/usr/src/cmd/fmt/head.c b/deleted_files/usr/src/cmd/fmt/head.c
index 12f44beac0..12f44beac0 100644
--- a/usr/src/cmd/fmt/head.c
+++ b/deleted_files/usr/src/cmd/fmt/head.c
diff --git a/usr/src/cmd/mail/maid.c b/deleted_files/usr/src/cmd/mail/maid.c
index e2eb72780e..e2eb72780e 100644
--- a/usr/src/cmd/mail/maid.c
+++ b/deleted_files/usr/src/cmd/mail/maid.c
diff --git a/usr/src/cmd/fmt/fmt.c b/usr/src/cmd/fmt/fmt.c
index 28e035a258..816b8a3f89 100644
--- a/usr/src/cmd/fmt/fmt.c
+++ b/usr/src/cmd/fmt/fmt.c
@@ -20,7 +20,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 1997 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -47,7 +47,7 @@
* Author: Kurt Shoens (UCB) 12/7/78
*/
-#define NOSTR ((wchar_t *) 0) /* Null string pointer for lint */
+#define NOSTR ((wchar_t *)0) /* Null string pointer for lint */
#define MAXLINES 100 /* maximum mail header lines to verify */
wchar_t outbuf[BUFSIZ]; /* Sandbagged output line image */
@@ -85,12 +85,25 @@ enum hdr_type hdr_state = not_in_hdr;
wchar_t *hdrbuf[MAXLINES]; /* buffer to hold potential mail header lines */
int h_lines; /* index into lines of hdrbuf */
-int (*(split))();
+void (*(split))(wchar_t []);
extern int scrwidth(wchar_t);
+extern int ishead(char []);
-static void fill_hdrbuf(wchar_t line[]);
+
+static void fill_hdrbuf(wchar_t []);
static void header_chk(void);
static void process_hdrbuf(void);
+static void leadin(void);
+static void tabulate(wchar_t []);
+static void oflush(void);
+static void pack(wchar_t []);
+static void msplit(wchar_t []);
+static void csplit(wchar_t []);
+static void _wckind_init(void);
+static void prefix(wchar_t []);
+static void fmt(FILE *);
+static int setopt(char *);
+int _wckind(wchar_t);
/*
* Drive the whole formatter by managing input files. Also,
@@ -98,15 +111,14 @@ static void process_hdrbuf(void);
* at the end.
*/
+int
main(int argc, char **argv)
{
- register FILE *fi;
+ FILE *fi;
char sobuf[BUFSIZ];
- register char *cp;
+ char *cp;
int nofile;
char *locale;
- int csplit(), msplit();
- void _wckind_init();
outp = NOSTR;
setbuf(stdout, sobuf);
@@ -116,7 +128,7 @@ main(int argc, char **argv)
split = csplit;
} else {
split = msplit;
- (void) _wckind_init();
+ _wckind_init();
}
if (argc < 2) {
single:
@@ -141,8 +153,7 @@ single:
if (nofile)
goto single;
oflush();
- exit(errs);
- /* NOTREACHED */
+ return (errs);
}
/*
@@ -151,11 +162,12 @@ single:
* and sending each line down for analysis.
*/
+static void
fmt(FILE *fi)
{
wchar_t linebuf[BUFSIZ], canonb[BUFSIZ];
- register wchar_t *cp, *cp2;
- register int col;
+ wchar_t *cp, *cp2;
+ int col;
wchar_t c;
char cbuf[BUFSIZ]; /* stores wchar_t string as char string */
@@ -282,11 +294,11 @@ fmt(FILE *fi)
* it on a line by itself.
*/
+static void
prefix(wchar_t line[])
{
- register wchar_t *cp;
- register int np;
- register int i;
+ wchar_t *cp;
+ int np;
int nosplit = 0; /* flag set if line should not be split */
if (line[0] == L'\0') {
@@ -368,9 +380,10 @@ prefix(wchar_t line[])
* line packer.
*/
+static void
csplit(wchar_t line[])
{
- register wchar_t *cp, *cp2;
+ wchar_t *cp, *cp2;
wchar_t word[BUFSIZ];
static const wchar_t *srchlist = (const wchar_t *) L".:!?";
@@ -406,9 +419,10 @@ csplit(wchar_t line[])
}
}
+static void
msplit(wchar_t line[])
{
- register wchar_t *cp, *cp2, prev;
+ wchar_t *cp, *cp2, prev;
wchar_t word[BUFSIZ];
static const wchar_t *srchlist = (const wchar_t *) L".:!?";
@@ -469,10 +483,11 @@ msplit(wchar_t line[])
* just give it its own and hope for the best.
*/
+static void
pack(wchar_t word[])
{
- register wchar_t *cp;
- register int s, t;
+ wchar_t *cp;
+ int s, t;
if (outp == NOSTR)
leadin();
@@ -496,6 +511,7 @@ pack(wchar_t word[])
* line prefix.
*/
+static void
oflush(void)
{
if (outp == NOSTR)
@@ -510,10 +526,11 @@ oflush(void)
* output on standard output (finally).
*/
+static void
tabulate(wchar_t line[])
{
- register wchar_t *cp, *cp2;
- register int b, t;
+ wchar_t *cp;
+ int b, t;
/* Toss trailing blanks in the output line */
@@ -544,11 +561,12 @@ tabulate(wchar_t line[])
* leading blanks.
*/
-leadin()
+static void
+leadin(void)
{
- register int b;
- register wchar_t *cp;
- register int l;
+ int b;
+ wchar_t *cp;
+ int l;
switch (crown_state) {
case c_head:
@@ -580,6 +598,7 @@ leadin()
* Is s1 a prefix of s2??
*/
+static int
ispref(wchar_t *s1, wchar_t *s2)
{
@@ -593,8 +612,8 @@ ispref(wchar_t *s1, wchar_t *s2)
* Set an input option
*/
-setopt(cp)
- register char *cp;
+static int
+setopt(char *cp)
{
static int ws = 0;
@@ -628,14 +647,14 @@ setopt(cp)
#define LIB_WDRESOLVE "/usr/lib/locale/%s/LC_CTYPE/wdresolve.so"
#define WCHKIND "_wdchkind_"
-static int _wckind_c_locale();
+static int _wckind_c_locale(wchar_t);
-static int (*__wckind)() = _wckind_c_locale;
+static int (*__wckind)(wchar_t) = _wckind_c_locale;
static void *dlhandle = NULL;
-void
-_wckind_init()
+static void
+_wckind_init(void)
{
char *locale;
char path[MAXPATHLEN + 1];
@@ -653,7 +672,7 @@ _wckind_init()
(void) sprintf(path, LIB_WDRESOLVE, locale);
if ((dlhandle = dlopen(path, RTLD_LAZY)) != NULL) {
- __wckind = (int (*)(int))dlsym(dlhandle, WCHKIND);
+ __wckind = (int (*)(wchar_t))dlsym(dlhandle, WCHKIND);
if (__wckind != NULL)
return;
(void) dlclose(dlhandle);
@@ -666,16 +685,14 @@ c_locale:
int
-_wckind(wc)
-wchar_t wc;
+_wckind(wchar_t wc)
{
return (*__wckind) (wc);
}
static int
-_wckind_c_locale(wc)
-wchar_t wc;
+_wckind_c_locale(wchar_t wc)
{
int ret;
@@ -732,7 +749,7 @@ header_chk(void)
for (l = 0; l < h_lines; l++) {
/* skip initial blanks */
for (cp = hdrbuf[l]; *cp == L' '; cp++);
- for (hp = &headnames[0]; *hp != (wchar_t *) 0; hp++)
+ for (hp = &headnames[0]; *hp != (wchar_t *)0; hp++)
if (ispref(*hp, cp)) {
hdrcount++;
break;
diff --git a/usr/src/cmd/fmt/inc.flg b/usr/src/cmd/fmt/inc.flg
new file mode 100755
index 0000000000..c223ee0e7e
--- /dev/null
+++ b/usr/src/cmd/fmt/inc.flg
@@ -0,0 +1,30 @@
+#!/bin/sh
+#
+# CDDL HEADER START
+#
+# The contents of this file are subject to the terms of the
+# Common Development and Distribution License, Version 1.0 only
+# (the "License"). You may not use this file except in compliance
+# with the License.
+#
+# You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+# or http://www.opensolaris.org/os/licensing.
+# See the License for the specific language governing permissions
+# and limitations under the License.
+#
+# When distributing Covered Code, include this CDDL HEADER in each
+# file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+# If applicable, add the following below this CDDL HEADER, with the
+# fields enclosed by brackets "[]" replaced with your own identifying
+# information: Portions Copyright [yyyy] [name of copyright owner]
+#
+# CDDL HEADER END
+#
+# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+# Use is subject to license terms.
+
+#ident "%Z%%M% %I% %E% SMI"
+
+echo_file usr/src/cmd/mailx/Makefile
+echo_file usr/src/cmd/mailx/head.c
+find_files "*.h" usr/src/cmd/mailx/hdr
diff --git a/usr/src/cmd/mail/Makefile b/usr/src/cmd/mail/Makefile
index edc35db692..648d786859 100644
--- a/usr/src/cmd/mail/Makefile
+++ b/usr/src/cmd/mail/Makefile
@@ -21,7 +21,7 @@
#
#
#
-# Copyright 1989, 2002 Sun Microsystems, Inc. All rights reserved.
+# Copyright 2005 Sun Microsystems, Inc. All rights reserved.
# Use is subject to license terms.
#
# ident "%Z%%M% %I% %E% SMI"
@@ -51,7 +51,7 @@ MAILOBJS= add_recip.o cat.o ckdlivopts.o \
pickFrom.o pipletr.o poplist.o printhdr.o printmail.o \
pushlist.o savehdrs.o sel_disp.o sendlist.o \
sendmail.o setsig.o \
- stamp.o Tout.o maid.o
+ stamp.o Tout.o
MAILSRC= $(MAILOBJS:%.o=%.c)
diff --git a/usr/src/cmd/mail/add_recip.c b/usr/src/cmd/mail/add_recip.c
index 29159034a1..13fb8519b3 100644
--- a/usr/src/cmd/mail/add_recip.c
+++ b/usr/src/cmd/mail/add_recip.c
@@ -19,19 +19,23 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
#pragma ident "%Z%%M% %I% %E% SMI"
- /* SVr4.0 1.5 */
/*
NAME
add_recip, madd_recip - add recipients to recipient list
SYNOPSIS
int add_recip(reciplist *plist, char *name, int checkdups)
- int madd_recip(reciplist *plist, char *name, int checkdups)
+ void madd_recip(reciplist *plist, char *name, int checkdups)
DESCRIPTION
add_recip() adds the name to the recipient linked list.
@@ -44,10 +48,8 @@
#include "mail.h"
-add_recip (plist, name, checkdups)
-reciplist *plist;
-char *name;
-int checkdups;
+int
+add_recip(reciplist *plist, char *name, int checkdups)
{
char *p;
static char pn[] = "add_recip";
@@ -95,10 +97,8 @@ int checkdups;
return(1);
}
-madd_recip (plist, namelist, checkdups)
-reciplist *plist;
-char *namelist;
-int checkdups;
+void
+madd_recip(reciplist *plist, char *namelist, int checkdups)
{
char *name;
for (name = strtok(namelist, " \t"); name; name = strtok((char*)0, " \t"))
diff --git a/usr/src/cmd/mail/copylet.c b/usr/src/cmd/mail/copylet.c
index 2e61f9b1f2..63e02034b4 100644
--- a/usr/src/cmd/mail/copylet.c
+++ b/usr/src/cmd/mail/copylet.c
@@ -19,18 +19,18 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
/*
- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
+
/*
NAME
copylet - copy a given letter to a file pointer
@@ -49,8 +49,8 @@
Returns TRUE on a completely successful copy.
*/
-copylet(letnum, f, type)
-register FILE *f;
+int
+copylet(int letnum, FILE *f, int type)
{
int pos = ftell(f);
int rc = xxxcopylet(letnum, f, type);
@@ -68,8 +68,8 @@ register FILE *f;
return(rc);
}
-xxxcopylet(letnum, f, type)
-register FILE *f;
+int
+xxxcopylet(int letnum, FILE *f, int type)
{
static char pn[] = "copylet";
char buf[LSIZE], lastc;
diff --git a/usr/src/cmd/mail/getcomment.c b/usr/src/cmd/mail/getcomment.c
index ff258f31e9..ac8674c066 100644
--- a/usr/src/cmd/mail/getcomment.c
+++ b/usr/src/cmd/mail/getcomment.c
@@ -19,12 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
#pragma ident "%Z%%M% %I% %E% SMI"
- /* SVr4.0 2. */
+
#include "mail.h"
/*
* Get comment field, if any, from line.
@@ -33,12 +38,12 @@
* -1 ==> no closing (terminating) paren found for comment.
*/
-getcomment(s, q)
-register char *s;
-register char *q; /* Copy comment, if found, to here */
+int
+getcomment(char *s, char *q)
+ /* Copy comment, if found, to q */
{
- register char *p, *sav_q;
- register int depth = 0;
+ char *p, *sav_q;
+ int depth = 0;
if ((p = strchr(s, '(')) == (char *)NULL) {
/* no comment found */
diff --git a/usr/src/cmd/mail/gethead.c b/usr/src/cmd/mail/gethead.c
index 6b72936efb..be671b8a23 100644
--- a/usr/src/cmd/mail/gethead.c
+++ b/usr/src/cmd/mail/gethead.c
@@ -19,15 +19,14 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
/*
- * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
@@ -200,7 +199,7 @@ gethead(int current, int all)
}
void
-tmperr()
+tmperr(void)
{
fclose(tmpf);
errmsg(E_TMP, "");
@@ -210,8 +209,8 @@ tmperr()
* Write a string out to tmp file, with error checking.
* Return 1 on success, else 0
*/
-wtmpf(str, length)
-char *str;
+int
+wtmpf(char *str, int length)
{
if (fwrite(str, 1, length, tmpf) != length) {
tmperr();
@@ -225,10 +224,7 @@ char *str;
* return number of bytes in length
*/
int
-getline(ptr2line, max, f)
-char *ptr2line;
-int max;
-FILE *f;
+getline(char *ptr2line, int max, FILE *f)
{
int i, ch;
for (i = 0; i < max-1 && (ch = getc(f)) != EOF; )
@@ -241,7 +237,7 @@ FILE *f;
* Make temporary file for letter
*/
void
-mktmp()
+mktmp(void)
{
static char tmpl[] = "/var/tmp/mailXXXXXX";
int fd = mkstemp(lettmp = tmpl);
@@ -257,8 +253,8 @@ mktmp()
* Get a number from user's reply,
* return its value or zero if none present, -1 on error
*/
-getnumbr(s)
-char *s;
+int
+getnumbr(char *s)
{
int k = 0;
@@ -283,7 +279,8 @@ char *s;
* If valid msgnum return 1,
* else print message and return 0
*/
-validmsg(i)
+int
+validmsg(int i)
{
if ((i < 0) || (i > nlet)) {
printf("No such message\n");
@@ -296,9 +293,7 @@ validmsg(i)
* Set letter to passed status, and adjust changed as necessary
*/
void
-setletr(letter, status)
-int letter;
-int status;
+setletr(int letter, int status)
{
if (status == ' ') {
if (let[letter].change != ' ')
diff --git a/usr/src/cmd/mail/islocal.c b/usr/src/cmd/mail/islocal.c
index ae0a4772d5..508f6b7b70 100644
--- a/usr/src/cmd/mail/islocal.c
+++ b/usr/src/cmd/mail/islocal.c
@@ -19,6 +19,11 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
@@ -30,9 +35,8 @@
/*
* islocal (char *user, uid_t *puid) - see if user exists on this system
*/
-islocal(user, puid)
-char *user;
-uid_t *puid;
+int
+islocal(char *user, uid_t *puid)
{
char fname[MAXPATHLEN];
struct stat statb;
diff --git a/usr/src/cmd/mail/istext.c b/usr/src/cmd/mail/istext.c
index 799d51f159..72d5ce5d1d 100644
--- a/usr/src/cmd/mail/istext.c
+++ b/usr/src/cmd/mail/istext.c
@@ -19,23 +19,27 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1. */
+#pragma ident "%Z%%M% %I% %E% SMI"
+
#include "mail.h"
/*
* istext(line, size) - check for text characters
*/
int
-istext(s, size)
-register unsigned char *s;
-int size;
+istext(unsigned char *s, int size)
{
- register unsigned char *ep;
- register c;
+ unsigned char *ep;
+ int c;
for (ep = s+size; --ep >= s; ) {
c = *ep;
diff --git a/usr/src/cmd/mail/mail.h b/usr/src/cmd/mail/mail.h
index e22a541778..35c3296ee5 100644
--- a/usr/src/cmd/mail/mail.h
+++ b/usr/src/cmd/mail/mail.h
@@ -19,15 +19,14 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
/*
- * Copyright 2003 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
#ifndef _MAIL_H
#define _MAIL_H
@@ -332,7 +331,7 @@ extern void createmf(uid_t uid, char *file);
extern void del_reciplist (reciplist *list);
extern void delete(int);
extern void doFopt(void);
-extern void done(int);
+extern void done(int) __NORETURN;
extern void sig_done(int);
extern FILE *doopen(char *file, char *type, int errnum);
extern int dowait(pid_t pidval);
@@ -355,7 +354,7 @@ extern int islocal(char *user, uid_t *puid);
extern int istext(unsigned char *s, int size);
extern int legal(char *file);
extern void lock(char *user);
-extern int madd_recip(reciplist *plist, char *name, int checkdups);
+extern void madd_recip(reciplist *plist, char *name, int checkdups);
extern char *mailcompile(string *pattern, int *retlen, int *retnbra);
extern void mkdead(void);
extern void mktmp(void);
@@ -433,7 +432,7 @@ extern int islocal();
extern int istext();
extern int legal();
extern void lock();
-extern int madd_recip();
+extern void madd_recip();
extern char *mailcompile();
extern void mkdead();
extern void mktmp();
diff --git a/usr/src/cmd/mail/main.c b/usr/src/cmd/mail/main.c
index ffe89d581c..009e02cb3b 100644
--- a/usr/src/cmd/mail/main.c
+++ b/usr/src/cmd/mail/main.c
@@ -19,14 +19,14 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
/*
- * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
@@ -39,8 +39,8 @@
* mail [ -tw ] [ -m messagetype ] persons
* rmail [ -tw ] persons
*/
-main(argc, argv)
-char **argv;
+int
+main(int argc, char **argv)
{
register int i;
char *cptr, *p;
@@ -240,5 +240,5 @@ char **argv;
sending = TRUE;
sendmail(argc, argv);
}
- done(0); /*NOTREACHED*/
+ done(0);
}
diff --git a/usr/src/cmd/mail/parse.c b/usr/src/cmd/mail/parse.c
index c449264b16..6fc32764f1 100644
--- a/usr/src/cmd/mail/parse.c
+++ b/usr/src/cmd/mail/parse.c
@@ -19,22 +19,27 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 2.1 */
+#pragma ident "%Z%%M% %I% %E% SMI"
+
#include "mail.h"
/*
Parse the command line.
Return index of first non-option field (i.e. user)
*/
-parse(argc, argv)
-int argc;
-char **argv;
+int
+parse(int argc, char **argv)
{
- register int c;
- register char *tmailsurr;
+ int c;
+ char *tmailsurr;
static char pn[] = "parse";
/*
diff --git a/usr/src/cmd/mail/pckaffspot.c b/usr/src/cmd/mail/pckaffspot.c
index 51cddaf0e5..7ffdf6e08b 100644
--- a/usr/src/cmd/mail/pckaffspot.c
+++ b/usr/src/cmd/mail/pckaffspot.c
@@ -19,12 +19,16 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
#pragma ident "%Z%%M% %I% %E% SMI"
- /* SVr4.0 2. */
+
#include "mail.h"
/*
* If any H_AFWDFROM lines in msg, decide where to put them.
@@ -33,10 +37,11 @@
* > 0 ==> Header line type after (before) which to place H_AFWDFROM
* lines and H_AFWDCNT
*/
-pckaffspot()
+int
+pckaffspot(void)
{
static char pn[] = "pckaffspot";
- register int rc;
+ int rc;
if (hdrlines[H_AFWDFROM].head == (struct hdrs *)NULL) {
rc = -1;
diff --git a/usr/src/cmd/mail/pckrcvspot.c b/usr/src/cmd/mail/pckrcvspot.c
index 87fbfdbbcc..bde3dfa851 100644
--- a/usr/src/cmd/mail/pckrcvspot.c
+++ b/usr/src/cmd/mail/pckrcvspot.c
@@ -19,12 +19,16 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
#pragma ident "%Z%%M% %I% %E% SMI"
- /* SVr4.0 2. */
+
#include "mail.h"
/*
* If any H_RECEIVED lines in msg, decide where to put them.
@@ -32,10 +36,11 @@
* -1 ==> No H_RECEIVED lines to be printed.
* > 0 ==> Header line type after (before) which to place H_RECEIVED lines
*/
-pckrcvspot()
+int
+pckrcvspot(void)
{
static char pn[] = "pckrcvspot";
- register int rc;
+ int rc;
if (hdrlines[H_RECEIVED].head == (struct hdrs *)NULL) {
rc = -1;
diff --git a/usr/src/cmd/mail/pipletr.c b/usr/src/cmd/mail/pipletr.c
index cfc22ac017..557d8bbcf1 100644
--- a/usr/src/cmd/mail/pipletr.c
+++ b/usr/src/cmd/mail/pipletr.c
@@ -19,18 +19,22 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
-dowait(pidval)
-pid_t pidval;
+int
+dowait(pid_t pidval)
{
- register pid_t w;
+ pid_t w;
int status;
void (*istat)(), (*qstat)();
@@ -61,8 +65,8 @@ pid_t pidval;
return:
status -> command exit status
*/
-systm(s)
-char *s;
+int
+systm(char *s)
{
pid_t pid;
diff --git a/usr/src/cmd/mail/printhdr.c b/usr/src/cmd/mail/printhdr.c
index 4852a0aa8d..9188793dcd 100644
--- a/usr/src/cmd/mail/printhdr.c
+++ b/usr/src/cmd/mail/printhdr.c
@@ -19,27 +19,23 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#pragma ident "%Z%%M% %I% %E% SMI" /* SVr4.0 2. */
-
-
/*
- * Copyright 2002 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
+#pragma ident "%Z%%M% %I% %E% SMI"
+
#include "mail.h"
-printhdr(type, hdrtype, hptr, fp)
-int hdrtype;
-struct hdrs *hptr;
-FILE *fp;
+int
+printhdr(int type, int hdrtype, struct hdrs *hptr, FILE *fp)
{
char buf[1024];
- register int n;
+ int n;
struct hdrs *contptr;
diff --git a/usr/src/cmd/mail/sel_disp.c b/usr/src/cmd/mail/sel_disp.c
index 9b228d674d..0049391ef9 100644
--- a/usr/src/cmd/mail/sel_disp.c
+++ b/usr/src/cmd/mail/sel_disp.c
@@ -19,10 +19,14 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
@@ -34,13 +38,11 @@
* the default output mode will be listed in the seldisp[] array.
* This can all be overridden via the 'P' command at the ? prompt.
*/
-sel_disp (type, hdrtype, s)
-int type;
-int hdrtype;
-char *s;
+int
+sel_disp(int type, int hdrtype, char *s)
{
static char pn[] = "sel_disp";
- register char *p;
+ char *p;
static int sav_lastrc = 0;
int i, rc = 0;
diff --git a/usr/src/cmd/mail/sendlist.c b/usr/src/cmd/mail/sendlist.c
index 9bde5837d5..00d5696a33 100644
--- a/usr/src/cmd/mail/sendlist.c
+++ b/usr/src/cmd/mail/sendlist.c
@@ -19,14 +19,13 @@
*
* CDDL HEADER END
*/
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-
-
/*
- * Copyright 2001-2002 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+
#pragma ident "%Z%%M% %I% %E% SMI"
#include "mail.h"
@@ -53,11 +52,10 @@
static char *sendmail_prog = SENDMAIL;
+static void notifybiff(char *);
+
int
-sendlist(list, letnum, level)
-reciplist *list;
-int letnum;
-int level;
+sendlist(reciplist *list, int letnum, int level)
{
recip *to;
int rc = 0;
@@ -141,9 +139,7 @@ int level;
int
-send_mbox(mbox, letnum)
-char *mbox;
-int letnum;
+send_mbox(char *mbox, int letnum)
{
char file[PATH_MAX];
char biffmsg[PATH_MAX];
@@ -211,8 +207,8 @@ done:
#include <sys/socket.h>
#include <netinet/in.h>
-notifybiff(msg)
- char *msg;
+static void
+notifybiff(char *msg)
{
static struct sockaddr_in addr;
static int f = -1;
diff --git a/usr/src/cmd/tar/tar.c b/usr/src/cmd/tar/tar.c
index 9e1677a3aa..9a005ce4b7 100644
--- a/usr/src/cmd/tar/tar.c
+++ b/usr/src/cmd/tar/tar.c
@@ -20,7 +20,7 @@
* CDDL HEADER END
*/
/*
- * Copyright 2004 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -153,7 +153,7 @@ int utimes(const char *path, const struct timeval timeval_ptr[]);
#define OCTAL7CHAR 2
#else
/* normal values */
-#define TAR_OFFSET_MAX 077777777777
+#define TAR_OFFSET_MAX 077777777777ULL
#define OCTAL7CHAR 07777777
#endif
diff --git a/usr/src/ucbcmd/plot/atoplot.c b/usr/src/ucbcmd/plot/atoplot.c
index 70df691e6e..a527e0e122 100644
--- a/usr/src/ucbcmd/plot/atoplot.c
+++ b/usr/src/ucbcmd/plot/atoplot.c
@@ -1,28 +1,31 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
float deltx;
float delty;
-char *mapLineType();
+static void fplt(FILE *);
+static int getsi(FILE *);
+static void getstr(char *, FILE *);
+static char *mapLineType(char *);
-main(argc,argv) char **argv; {
+int
+main(int argc, char **argv)
+{
int std=1;
FILE *fin;
@@ -50,11 +53,13 @@ main(argc,argv) char **argv; {
}
if (std)
fplt( stdin );
- exit(0);
- }
+ return (0);
+}
-fplt(fin) FILE *fin; {
+static void
+fplt(FILE *fin)
+{
int c;
char s[256];
int xi,yi,x0,y0,x1,y1,r,dx,n,i;
@@ -135,8 +140,12 @@ fplt(fin) FILE *fin; {
}
}
closepl();
- }
-getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
+}
+
+/* get an integer stored in 2 ascii bytes. */
+static int
+getsi(FILE *fin)
+{
int i;
if ( fscanf(fin, " %d", & i) != 1 ) {
@@ -144,7 +153,10 @@ getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
}
return( i );
}
-getstr(s,fin) char *s; FILE *fin; {
+
+static void
+getstr(char *s, FILE *fin)
+{
for( ; *s = getc(fin); s++)
if(*s == '\n')
break;
@@ -163,9 +175,8 @@ char *lineMap[] = {
"dotdotdash", /* line type 8 */
} ;
-char *
-mapLineType( cp )
- char *cp;
+static char *
+mapLineType(char *cp)
{
int i;
diff --git a/usr/src/ucbcmd/plot/crtdriver.c b/usr/src/ucbcmd/plot/crtdriver.c
index 8159e55754..f6d2e21a82 100644
--- a/usr/src/ucbcmd/plot/crtdriver.c
+++ b/usr/src/ucbcmd/plot/crtdriver.c
@@ -1,21 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
This driver is used with crtplot.c.
@@ -33,7 +30,13 @@ for crt's.
float deltx;
float delty;
-main(argc,argv) char **argv; {
+static void fplt(FILE *);
+static int getsi(FILE *);
+static void getstr(char *, FILE *);
+
+int
+main(int argc, char **argv)
+{
int std=1;
FILE *fin;
@@ -61,10 +64,12 @@ main(argc,argv) char **argv; {
if (std)
fplt( stdin );
- exit(0);
- }
+ return (0);
+}
-fplt(fin) FILE *fin; {
+static void
+fplt(FILE *fin)
+{
int c;
char s[256];
int xi,yi,x0,y0,x1,y1,r/*,dx,n,i*/;
@@ -134,8 +139,12 @@ fplt(fin) FILE *fin; {
}
}
closepl();
- }
-getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
+}
+
+/* get an integer stored in 2 ascii bytes. */
+static int
+getsi(FILE *fin)
+{
short a, b;
if((b = getc(fin)) == EOF)
return(EOF);
@@ -144,7 +153,10 @@ getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
a = a<<8;
return(a|b);
}
-getstr(s,fin) char *s; FILE *fin; {
+
+static void
+getstr(char *s, FILE *fin)
+{
for( ; *s = getc(fin); s++)
if(*s == '\n')
break;
diff --git a/usr/src/ucbcmd/plot/crtplot.c b/usr/src/ucbcmd/plot/crtplot.c
index 5eeefb2f65..7f317eb6e2 100644
--- a/usr/src/ucbcmd/plot/crtplot.c
+++ b/usr/src/ucbcmd/plot/crtplot.c
@@ -1,9 +1,11 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
@@ -11,11 +13,7 @@
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
This plotting routine interprets plot commands and outputs them onto
@@ -28,7 +26,6 @@ because some function names conflicted with the curses library.
(That's what you get when you have a flat name space!)
*/
-
#include <curses.h>
#include <math.h>
#include <signal.h>
@@ -39,16 +36,17 @@ because some function names conflicted with the curses library.
#define plot_movech(y, x, ch) { plot_move(x, y); plot_addch(ch); }
-
static double lowX, rangeX; /* min and range of x */
static double lowY, rangeY; /* min and range of y */
static int lastX, lastY; /* last point plotted */
-
+void arc(int, int, int, int, int, int);
+void dda_line(char, int, int, int, int);
char *getenv();
+
/* This routine just moves the cursor. */
-screen_move(y, x)
-int x,y;
+void
+screen_move(int y, int x)
{
/* must check for automatic wrap at last col */
if (!AM || (y < LINES -1) || (x < COLS -1)) {
@@ -60,8 +58,8 @@ int x,y;
/* This routine assumes the cursor is positioned correctly. */
-plot_addch(ch)
-char ch;
+void
+plot_addch(char ch)
{
putchar(ch);
if (++lastX >= COLS) {
@@ -78,51 +76,52 @@ char ch;
/* See the curses manual for what is been done and why. */
-openpl()
+void
+openpl(void)
{
-char *sp;
-void closepl();
-
-gettmode();
-if (sp=getenv("TERM"))
- setterm(sp);
-signal(SIGINT, closepl);
+ char *sp;
+ void closepl();
+ gettmode();
+ if (sp=getenv("TERM"))
+ setterm(sp);
+ signal(SIGINT, closepl);
}
-void closepl()
+void
+closepl(void)
{
-signal(SIGINT, SIG_IGN);
-/* Leave cursor at top of screen. */
-mvcur(LINES-1, COLS-1, 0, 0);
-endwin();
-exit(0);
+ signal(SIGINT, SIG_IGN);
+ /* Leave cursor at top of screen. */
+ mvcur(LINES-1, COLS-1, 0, 0);
+ endwin();
+ exit(0);
}
-plot_move(x,y)
-int x, y;
+void
+plot_move(int x, int y)
{
-screen_move(scaleY(y), scaleX(x));
+ screen_move(scaleY(y), scaleX(x));
}
-line(x0, y0, x1, y1)
-int x0, y0, x1, y1;
+void
+line(int x0, int y0, int x1, int y1)
{
-plot_movech(y0, x0, '*');
-dda_line('*', scaleX(x0), scaleY(y0), scaleX(x1), scaleY(y1));
+ plot_movech(y0, x0, '*');
+ dda_line('*', scaleX(x0), scaleY(y0), scaleX(x1), scaleY(y1));
}
-label(str)
-char *str;
+void
+label(char *str)
{
- reg i, length;
+ int i, length;
int strlen();
if ( (length=strlen(str)) > (COLS-lastX) )
@@ -131,65 +130,68 @@ char *str;
plot_addch(str[i]);
}
-plot_erase()
+void
+plot_erase(void)
{
-int _putchar();
-/*
-Some of these functions probably belong in openpl(). However, if the
-input is being typed in, putting them in openpl would not work
-since "noecho", etc would prevent (sort of) input. Notice that
-the driver calls openpl before doing anything. This is actually
-wrong, but it is what whoever originally wrote the driver decided
-to do. (openpl() in libplot does nothing -- that is the main problem!)
-*/
-_puts(TI);
-_puts(VS);
-
-noecho();
-nonl();
-tputs(CL, LINES, _putchar);
-mvcur(0, COLS-1, LINES-1, 0);
-lastX = 0;
-lastY = LINES-1;
+ int _putchar();
+ /*
+ Some of these functions probably belong in openpl(). However, if the
+ input is being typed in, putting them in openpl would not work
+ since "noecho", etc would prevent (sort of) input. Notice that
+ the driver calls openpl before doing anything. This is actually
+ wrong, but it is what whoever originally wrote the driver decided
+ to do. (openpl() in libplot does nothing -- that is the main problem!)
+ */
+ _puts(TI);
+ _puts(VS);
+
+ noecho();
+ nonl();
+ tputs(CL, LINES, _putchar);
+ mvcur(0, COLS-1, LINES-1, 0);
+ lastX = 0;
+ lastY = LINES-1;
}
-point(x, y)
-int x,y;
+void
+point(int x, int y)
{
-plot_movech(y, x, '*');
+ plot_movech(y, x, '*');
}
-cont(x, y)
-int x,y;
+void
+cont(int x, int y)
{
-dda_line('*', lastX-1, lastY, scaleX(x), scaleY(y));
+ dda_line('*', lastX-1, lastY, scaleX(x), scaleY(y));
}
-space(x0, y0, x1, y1)
-int x0, y0, x1, y1;
+void
+space(int x0, int y0, int x1, int y1)
{
-lowX = (double) x0;
-lowY = (double) y0;
-rangeX = COLS/(double) (x1 - x0);
-rangeY = LINES/(double) (y1 - y0);
+ lowX = (double) x0;
+ lowY = (double) y0;
+ rangeX = COLS/(double) (x1 - x0);
+ rangeY = LINES/(double) (y1 - y0);
}
-linemod(string)
-char *string;
+void
+linemod(char *string)
{
}
-
-/* See Neuman & Sproul for explanation and rationale. */
-/* Does not plot first point -- assumed that it is already plotted */
-dda_line(ch, x0, y0, x1, y1)
-char ch;
-int x0, y0, x1, y1; /* already transformed to screen coords */
+/*
+ * See Neuman & Sproul for explanation and rationale.
+ * Does not plot first point -- assumed that it is already plotted
+ *
+ * x0, y0, x1, and y1 are already transformed to screen coords
+ */
+void
+dda_line(char ch, int x0, int y0, int x1, int y1)
{
int length, i;
double deltaX, deltaY;
@@ -197,31 +199,30 @@ int x0, y0, x1, y1; /* already transformed to screen coords */
double floor();
int abs();
-length = abs(x1 - x0);
-if (abs(y1 -y0) > length)
- length = abs(y1 - y0);
+ length = abs(x1 - x0);
+ if (abs(y1 -y0) > length)
+ length = abs(y1 - y0);
-if (length == 0)
- return;
+ if (length == 0)
+ return;
-deltaX = (double) (x1 - x0)/(double) length;
-deltaY = (double) (y1 - y0)/(double) length;
+ deltaX = (double) (x1 - x0)/(double) length;
+ deltaY = (double) (y1 - y0)/(double) length;
-x = (double) x0 + 0.5;
-y = (double) y0 + 0.5;
+ x = (double) x0 + 0.5;
+ y = (double) y0 + 0.5;
-for (i=0; i < length; ++i)
- {
- x += deltaX;
- y += deltaY;
- screen_move((int) floor(y), (int) floor(x));
- plot_addch(ch);
+ for (i=0; i < length; ++i) {
+ x += deltaX;
+ y += deltaY;
+ screen_move((int) floor(y), (int) floor(x));
+ plot_addch(ch);
}
}
-circle (xc,yc,r)
-int xc,yc,r;
+void
+circle (int xc, int yc, int r)
{
arc(xc,yc, xc+r,yc, xc-r,yc);
arc(xc,yc, xc-r,yc, xc+r,yc);
@@ -231,8 +232,8 @@ int xc,yc,r;
/* should include test for equality? */
#define side(x,y) (a*(x)+b*(y)+c > 0.0 ? 1 : -1)
-arc(xc,yc,xbeg,ybeg,xend,yend)
-int xc,yc,xbeg,ybeg,xend,yend;
+void
+arc(int xc, int yc, int xbeg, int ybeg, int xend, int yend)
{
double r, radius, costheta, sintheta;
double a, b, c, x, y, tempX;
diff --git a/usr/src/ucbcmd/plot/debug.c b/usr/src/ucbcmd/plot/debug.c
index 8a89258de5..324f7ac6b0 100644
--- a/usr/src/ucbcmd/plot/debug.c
+++ b/usr/src/ucbcmd/plot/debug.c
@@ -1,28 +1,31 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
float deltx;
float delty;
-main(argc,argv) char **argv; {
+static void fplt(FILE *);
+static int getsi(FILE *);
+static void getstr(char *, FILE *);
+
+int
+main(int argc, char **argv)
+{
int std=1;
FILE *fin;
@@ -49,11 +52,13 @@ main(argc,argv) char **argv; {
}
if (std)
fplt( stdin );
- exit(0);
- }
+ return (0);
+}
-fplt(fin) FILE *fin; {
+static void
+fplt(FILE *fin)
+{
int c;
char s[256];
int xi,yi,x0,y0,x1,y1,r/*,dx,n,i*/;
@@ -122,8 +127,12 @@ fplt(fin) FILE *fin; {
}
}
printf("closepl\n");
- }
-getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
+}
+
+/* get an integer stored in 2 ascii bytes. */
+static int
+getsi(FILE *fin)
+{
short a, b;
if((b = getc(fin)) == EOF)
return(EOF);
@@ -132,7 +141,10 @@ getsi(fin) FILE *fin; { /* get an integer stored in 2 ascii bytes. */
a = a<<8;
return(a|b);
}
-getstr(s,fin) char *s; FILE *fin; {
+
+static void
+getstr(char *s, FILE *fin)
+{
for( ; *s = getc(fin); s++)
if(*s == '\n')
break;
diff --git a/usr/src/ucbcmd/plot/driver.c b/usr/src/ucbcmd/plot/driver.c
index 5c912e839f..b1254277d8 100644
--- a/usr/src/ucbcmd/plot/driver.c
+++ b/usr/src/ucbcmd/plot/driver.c
@@ -1,21 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
@@ -23,9 +20,12 @@ float deltx;
float delty;
int PlotRes;
-main(argc,argv)
- int argc;
- char *argv[];
+static void fplt(FILE *);
+static int getsi(FILE *);
+static void getstr(char *, FILE *);
+
+int
+main(int argc, char *argv[])
{
int std = 1;
char *progname;
@@ -59,13 +59,13 @@ main(argc,argv)
}
if (std)
fplt(stdin);
- exit(0);
+ return (0);
}
-fplt(fin)
- FILE *fin;
+static void
+fplt(FILE *fin)
{
- register int c;
+ int c;
char s[256];
int xi,yi,x0,y0,x1,y1,r,dx,n,i;
int pat[256];
@@ -143,8 +143,8 @@ fplt(fin)
}
/* get an integer stored in 2 ascii bytes. */
-getsi(fin)
- register FILE *fin;
+static int
+getsi(FILE *fin)
{
short a, b;
@@ -156,9 +156,8 @@ getsi(fin)
return(a|b);
}
-getstr(s, fin)
- register char *s;
- register FILE *fin;
+static void
+getstr(char *s, FILE *fin)
{
for( ; *s = getc(fin); s++)
diff --git a/usr/src/ucbcmd/plot/libplot/aed/aed.h b/usr/src/ucbcmd/plot/libplot/aed/aed.h
index fc1a312ae2..ef121b70e4 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/aed.h
+++ b/usr/src/ucbcmd/plot/libplot/aed/aed.h
@@ -1,20 +1,22 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#ifndef _AED_H
+#define _AED_H
+
+#pragma ident "%Z%%M% %I% %E% SMI"
+
/*
* Displays plot files on an AED512 graphics terminal.
*/
@@ -24,7 +26,7 @@
extern char dbuf[BUFSIZ]; /* Used to buffer display characters */
extern struct sgttyb sgttyb; /* Used to save terminal control bits */
-extern curx, cury; /* Current screen position */
+extern int curx, cury; /* Current screen position */
extern int xbot, ybot; /* Coordinates of screen lower-left corner */
extern int scale; /* The number of pixels per 2**12 units
* of world coordinates.
@@ -34,3 +36,5 @@ extern int scale; /* The number of pixels per 2**12 units
#define GRXMAX 511 /* Maximum x-coordinate of screen */
#define GRYMAX 482 /* Maximum y-coordinate of screen */
+
+#endif /* _AED_H */
diff --git a/usr/src/ucbcmd/plot/libplot/aed/arc.c b/usr/src/ucbcmd/plot/libplot/aed/arc.c
index c8d300492b..72192c14f0 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/arc.c
@@ -1,20 +1,20 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
-arc(){
+void
+arc(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/aed/box.c b/usr/src/ucbcmd/plot/libplot/aed/box.c
index dce4c8281b..b68c2a40fc 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/box.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/box.c
@@ -1,22 +1,21 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/circle.c b/usr/src/ucbcmd/plot/libplot/aed/circle.c
index a622681905..6ccbb0fc7a 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/circle.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -27,8 +25,8 @@
* A circle of radius r is drawn at (x,y).
*---------------------------------------------------------
*/
-circle(x, y, r)
-int x, y, r;
+void
+circle(int x, int y, int r)
{
char buf[3];
setcolor("01");
diff --git a/usr/src/ucbcmd/plot/libplot/aed/close.c b/usr/src/ucbcmd/plot/libplot/aed/close.c
index 468d4a3177..41ad3cf211 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/close.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/close.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -28,7 +26,8 @@
* The graphics display modes are reset.
*---------------------------------------------------------
*/
-closepl()
+void
+closepl(void)
{
fputs("Q00204\6", stdout);
(void) fflush(stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/cont.c b/usr/src/ucbcmd/plot/libplot/aed/cont.c
index 0d37692198..ec1303b568 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/cont.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -25,8 +23,8 @@
* Side Effects: As above.
*---------------------------------------------------------
*/
-cont(x, y)
-int x, y;
+void
+cont(int x, int y)
{
line(curx, cury, x, y);
}
diff --git a/usr/src/ucbcmd/plot/libplot/aed/dot.c b/usr/src/ucbcmd/plot/libplot/aed/dot.c
index a0d3dcca35..b2f772d891 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/dot.c
@@ -1,20 +1,20 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/aed/erase.c b/usr/src/ucbcmd/plot/libplot/aed/erase.c
index bdcd5172f6..46387560c4 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/erase.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -25,7 +23,8 @@
* Side Effects: The screen is cleared.
*---------------------------------------------------------
*/
-erase()
+void
+erase(void)
{
setcolor("FF");
putc('\14', stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/label.c b/usr/src/ucbcmd/plot/libplot/aed/label.c
index 78b55bfecc..227a316ac7 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/label.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/label.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -29,8 +27,8 @@
* The current position is updated accordingly.
*---------------------------------------------------------
*/
-label(s)
-char *s;
+void
+label(char *s)
{
setcolor("02");
putc('Q', stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/line.c b/usr/src/ucbcmd/plot/libplot/aed/line.c
index f1dbe93bf2..e5e8259631 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/line.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/line.c
@@ -1,13 +1,33 @@
+/*
+ * CDDL HEADER START
+ *
+ * The contents of this file are subject to the terms of the
+ * Common Development and Distribution License, Version 1.0 only
+ * (the "License"). You may not use this file except in compliance
+ * with the License.
+ *
+ * You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
+ * or http://www.opensolaris.org/os/licensing.
+ * See the License for the specific language governing permissions
+ * and limitations under the License.
+ *
+ * When distributing Covered Code, include this CDDL HEADER in each
+ * file and include the License file at usr/src/OPENSOLARIS.LICENSE.
+ * If applicable, add the following below this CDDL HEADER, with the
+ * fields enclosed by brackets "[]" replaced with your own identifying
+ * information: Portions Copyright [yyyy] [name of copyright owner]
+ *
+ * CDDL HEADER END
+ */
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -20,8 +40,8 @@
* A line is drawn on the screen between (x1, y1) and (x2, y2).
*---------------------------------------------------------
*/
-line(x1, y1, x2, y2)
-int x1, y1, x2, y2;
+void
+line(int x1, int y1, int x2, int y2)
{
setcolor("01");
putc('Q', stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/linemod.c b/usr/src/ucbcmd/plot/libplot/aed/linemod.c
index b081ceaa17..18b169c9f6 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/linemod.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -29,8 +27,8 @@
* or "dotdashed". If s isn't recognized, then "solid" is used.
*---------------------------------------------------------
*/
-linemod(s)
-char *s;
+void
+linemod(char *s)
{
if (strcmp(s, "dotted") == 0)
fputs("1AAFF", stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/move.c b/usr/src/ucbcmd/plot/libplot/aed/move.c
index 393d6f153c..0f0c7caad8 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/move.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/move.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -25,8 +23,8 @@
* Side Effects: As above.
*---------------------------------------------------------
*/
-move(x, y)
-int x, y;
+void
+move(int x, int y)
{
curx = x;
cury = y;
diff --git a/usr/src/ucbcmd/plot/libplot/aed/open.c b/usr/src/ucbcmd/plot/libplot/aed/open.c
index 6bbdc8befc..1a19feda04 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/open.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/open.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Displays plot files on a AED512 graphics terminal.
@@ -51,7 +49,8 @@ static int colors[] = {200, 200, 200, 0, 0, 125, 125, 0, 0, 125, 0, 0};
* Errors: None.
*---------------------------------------------------------
*/
-openpl()
+void
+openpl(void)
{
int flags, *p, i;
char dum[4];
diff --git a/usr/src/ucbcmd/plot/libplot/aed/point.c b/usr/src/ucbcmd/plot/libplot/aed/point.c
index 7b8fdb2e30..d45da4617d 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/point.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/point.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -28,8 +26,8 @@
* The point is made the current point.
*---------------------------------------------------------
*/
-point(x, y)
-int x, y;
+void
+point(int x, int y)
{
setcolor("01");
putc('Q', stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/space.c b/usr/src/ucbcmd/plot/libplot/aed/space.c
index 1bbc37b7e5..7c9fdd8e16 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/space.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/space.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -29,8 +27,8 @@
* Our own variables scale, xbot, and ybot are changed.
*---------------------------------------------------------
*/
-space(x0, y0, x1, y1)
-int x0, y0, x1, y1;
+void
+space(int x0, int y0, int x1, int y1)
{
int xscale, yscale, xsize, ysize;
xscale = (GRXMAX<<12)/(x1-x0);
diff --git a/usr/src/ucbcmd/plot/libplot/aed/subr.c b/usr/src/ucbcmd/plot/libplot/aed/subr.c
index 57ea924424..e771ae6ffc 100644
--- a/usr/src/ucbcmd/plot/libplot/aed/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/aed/subr.c
@@ -1,20 +1,18 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "aed.h"
@@ -35,12 +33,15 @@ static char hex[] = "0123456789ABCDEF";
* Side Effects:
* The string contains the value of the low-order nchars 4-bit chunks
* of val, as represented in hexadecimal. String is zero-filled.
+ *
+ * Parameters
+ * val - Integer value to be converted.
+ * string - Pointer to area for converted result.
+ * nchars - Number of characters to be converted.
*---------------------------------------------------------
*/
-chex(val, string, nchars)
-int val; /* Integer value to be converted. */
-char *string; /* Pointer to area for converted result. */
-int nchars; /* Number of characters to be converted. */
+void
+chex(int val, char *string, int nchars)
{
string = &(string[nchars]);
*string = '\0';
@@ -62,13 +63,15 @@ int nchars; /* Number of characters to be converted. */
* for values indicated by "xy20" in the user manual.
*
* Errors: None.
+ *
+ * Parameters:
+ * x, y - The coordinates to be output. Note: these
+ * are world coordinates, not screen ones. We
+ * scale in this routine.
*---------------------------------------------------------
*/
-outxy20(x, y)
-int x, y; /* The coordinates to be output. Note:
- * these are world coordinates, not screen
- * ones. We scale in this routine.
- */
+void
+outxy20(int x, int y)
{
char s1[4], s2[4], s3[4];
x = ((x - xbot) * scale)>>12;
@@ -87,12 +90,14 @@ int x, y; /* The coordinates to be output. Note:
* Side Effects:
* The current color in the display is set to pcolor, if it
* isn't that already.
+ *
+ * Parameter:
+ * pcolor - Pointer to a string giving the desired color
+ * in hexadecimal
*---------------------------------------------------------
*/
-setcolor(pcolor)
-char *pcolor; /* Pointer to a string giving the desired
- * color in hexadecimal.
- */
+void
+setcolor(char *pcolor)
{
static char curcolor[] = "xx";
if ((pcolor[0] != curcolor[0]) || (pcolor[1] != curcolor[1]))
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/arc.c b/usr/src/ucbcmd/plot/libplot/bitgraph/arc.c
index 6ba92aaddd..0a6ca1c5b0 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/arc.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
@@ -22,8 +20,8 @@
#define side(x,y) (a*(x)+b*(y)+c > 0.0 ? 1 : -1)
/* The beginning and ending points must be distinct. */
-arc(xc,yc,xbeg,ybeg,xend,yend)
-int xc,yc,xbeg,ybeg,xend,yend;
+void
+arc(int xc, int yc, int xbeg, int ybeg, int xend, int yend)
{
double r, radius, costheta, sintheta;
double a, b, c, x, y, tempX;
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/box.c b/usr/src/ucbcmd/plot/libplot/bitgraph/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/box.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/circle.c b/usr/src/ucbcmd/plot/libplot/bitgraph/circle.c
index 3fe8b150e9..9afb4cd11c 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/circle.c
@@ -1,24 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle (xc,yc,r)
-int xc,yc,r;
+void
+circle (int xc, int yc, int r)
{
arc(xc,yc, xc+r,yc, xc-r,yc);
arc(xc,yc, xc-r,yc, xc+r,yc);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/close.c b/usr/src/ucbcmd/plot/libplot/bitgraph/close.c
index e38aa6d949..7cb0e9bc79 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/close.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/close.c
@@ -1,26 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <signal.h>
#include "bg.h"
-closepl()
+void
+closepl(void)
{
/* recieve interupts */
signal(SIGINT, SIG_IGN);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/cont.c b/usr/src/ucbcmd/plot/libplot/bitgraph/cont.c
index 21e8dd0a93..cdac4c4132 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/cont.c
@@ -1,26 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
-cont(xi,yi)
-int xi,yi;
+void
+cont(int xi, int yi)
{
currentx = scaleX(xi);
currenty = scaleY(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/dot.c b/usr/src/ucbcmd/plot/libplot/bitgraph/dot.c
index 6aa953f3a3..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/dot.c
@@ -1,21 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/erase.c b/usr/src/ucbcmd/plot/libplot/bitgraph/erase.c
index f250b14ac4..b098807156 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/erase.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
-erase()
+void
+erase(void)
{
putchar( ESC );
printf("[H");
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/label.c b/usr/src/ucbcmd/plot/libplot/bitgraph/label.c
index bcf807b09f..84ed8dcae2 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/label.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/label.c
@@ -1,24 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-label(s)
-char *s;
+void
+label(char *s)
{
printf("%s", s);
}
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/line.c b/usr/src/ucbcmd/plot/libplot/bitgraph/line.c
index ee9771b65e..30e1b92073 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/line.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/line.c
@@ -1,26 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
-line(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+line(int x0, int y0, int x1, int y1)
{
if(scaleX(x0)==currentx && scaleY(y0)==currenty)
cont(x1,y1);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/linemod.c b/usr/src/ucbcmd/plot/libplot/bitgraph/linemod.c
index 11f3e9e517..ee4f67b863 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/linemod.c
@@ -1,21 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-linemod(){
+void
+linemod(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/move.c b/usr/src/ucbcmd/plot/libplot/bitgraph/move.c
index 7fb50e4584..1d16e788f0 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/move.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/move.c
@@ -1,26 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
-move(xi,yi)
-int xi,yi;
+void
+move(int xi, int yi)
{
currentx = scaleX(xi);
currenty = scaleY(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/open.c b/usr/src/ucbcmd/plot/libplot/bitgraph/open.c
index 9735e7a3cc..a096c7ca4f 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/open.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/open.c
@@ -1,21 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Displays plot files on a BBN bitgraph terminal.
@@ -30,7 +27,8 @@ double lowx = 0.0;
double lowy = 0.0;
double scale = 1.0;
-openpl()
+void
+openpl(void)
{
void closepl();
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/point.c b/usr/src/ucbcmd/plot/libplot/bitgraph/point.c
index a177c3bffd..6eb6240959 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/point.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/point.c
@@ -1,24 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-point(xi, yi)
-int xi, yi;
+void
+point(int xi, int yi)
{
move(xi, yi);
label(".");
diff --git a/usr/src/ucbcmd/plot/libplot/bitgraph/space.c b/usr/src/ucbcmd/plot/libplot/bitgraph/space.c
index e98efec98b..16e993e587 100644
--- a/usr/src/ucbcmd/plot/libplot/bitgraph/space.c
+++ b/usr/src/ucbcmd/plot/libplot/bitgraph/space.c
@@ -1,26 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "bg.h"
-space(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+space(int x0, int y0, int x1, int y1)
{
double scalex, scaley;
lowx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/arc.c b/usr/src/ucbcmd/plot/libplot/dumb/arc.c
index 7bd038a3e2..d5727f5b2c 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/arc.c
@@ -1,24 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-arc(xc,yc,xbeg,ybeg,xend,yend)
-int xc,yc,xbeg,ybeg,xend,yend;
+void
+arc(int xc, int yc, int xbeg, int ybeg, int xend, int yend)
{
}
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/box.c b/usr/src/ucbcmd/plot/libplot/dumb/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/box.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/circle.c b/usr/src/ucbcmd/plot/libplot/dumb/circle.c
index 6dab0dce38..1baa52d770 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/circle.c
@@ -1,19 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle(){
+void
+circle(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/close.c b/usr/src/ucbcmd/plot/libplot/dumb/close.c
index 979b8dc369..14ef59e64f 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/close.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/close.c
@@ -1,25 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <signal.h>
#include "dumb.h"
-closepl()
+void
+closepl(void)
{
int i, j;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/cont.c b/usr/src/ucbcmd/plot/libplot/dumb/cont.c
index 3233e5b49f..014f337aad 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/cont.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-cont(x, y)
- int x,y;
+void
+cont(int x, int y)
{
int x1, y1;
x1 = x;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/dot.c b/usr/src/ucbcmd/plot/libplot/dumb/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/erase.c b/usr/src/ucbcmd/plot/libplot/dumb/erase.c
index dae078fe39..5aec3c4706 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/erase.c
@@ -1,26 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-erase()
+void
+erase(void)
{
- register int i, j;
+ int i, j;
for(i=0;i<COLS;i++)
for(j=0;j<LINES;j++)
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/label.c b/usr/src/ucbcmd/plot/libplot/dumb/label.c
index db28a34284..f11c569269 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/label.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/label.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-label(string)
- char *string;
+void
+label(char *string)
{
while(*string != '\0' && currentx < COLS){
screenmat[currentx][currenty] = *string++;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/line.c b/usr/src/ucbcmd/plot/libplot/dumb/line.c
index 01ae1418eb..07bdcb5752 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/line.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/line.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-line(x0, y0, x1, y1)
- int x0, y0, x1, y1;
+void
+line(int x0, int y0, int x1, int y1)
{
int x,y;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/linemod.c b/usr/src/ucbcmd/plot/libplot/dumb/linemod.c
index 47ceef55d3..675c429e0a 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/linemod.c
@@ -1,22 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-linemod(s)
-char *s;
+void
+linemod(char *s)
{
}
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/move.c b/usr/src/ucbcmd/plot/libplot/dumb/move.c
index 2e6ea7ad32..61ec8177e6 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/move.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/move.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-move(x,y)
-int x,y;
+void
+move(int x, int y)
{
scale(x, y);
currentx = x;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/open.c b/usr/src/ucbcmd/plot/libplot/dumb/open.c
index 26dad93202..50b2ef0b02 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/open.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/open.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* This accepts plot file formats and produces the appropriate plots
@@ -35,7 +33,8 @@ int COLS,LINES;
/* A very large screen! (probably should use malloc) */
char screenmat[MAXCOLS][MAXLINES];
-openpl()
+void
+openpl(void)
{
void closepl();
int i, j;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/point.c b/usr/src/ucbcmd/plot/libplot/dumb/point.c
index c6e72da637..fb6dbdb6a4 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/point.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/point.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-point(x, y)
- int x,y;
+void
+point(int x, int y)
{
scale(x, y);
currentx = x;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/space.c b/usr/src/ucbcmd/plot/libplot/dumb/space.c
index dad2cff44b..c766243499 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/space.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/space.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-space(x0, y0, x1, y1)
- int x0, y0, x1, y1;
+void
+space(int x0, int y0, int x1, int y1)
{
minX = x0;
rangeX = x1 -x0;
diff --git a/usr/src/ucbcmd/plot/libplot/dumb/subr.c b/usr/src/ucbcmd/plot/libplot/dumb/subr.c
index 102c483878..5ee8bf841e 100644
--- a/usr/src/ucbcmd/plot/libplot/dumb/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/dumb/subr.c
@@ -1,28 +1,31 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "dumb.h"
-/* Does not plot first point -- assumed that it is already plotted */
-dda_line(ch, x0, y0, x1, y1)
- char ch;
- int x0, y0; /* already transformed to screen coords */
- int x1, y1; /* untransformed */
+/*
+ * Does not plot first point -- assumed that it is already plotted
+ *
+ * Parameters
+ * ch
+ * x0, y0 - already transformed to screen coords
+ * x1, y1 - untransformed
+ */
+void
+dda_line(char ch, int x0, int y0, int x1, int y1)
{
int length, i;
double deltaX, deltaY;
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/arc.c b/usr/src/ucbcmd/plot/libplot/gigi/arc.c
index edaec6a548..2e3e9d0ad5 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/arc.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
@@ -34,8 +32,8 @@
#define side(x,y) (a*(x)+b*(y)+c > 0.0 ? 1 : -1)
-arc(xcent,ycent,xbeg,ybeg,xend,yend)
-int xcent,ycent,xbeg,ybeg,xend,yend;
+void
+arc(int xcent, int ycent, int xbeg, int ybeg, int xend, int yend)
{
double radius2, c2;
double a,b,c;
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/box.c b/usr/src/ucbcmd/plot/libplot/gigi/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/box.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/circle.c b/usr/src/ucbcmd/plot/libplot/gigi/circle.c
index f3442861ab..dbcb78f547 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/circle.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-circle (xc,yc,r)
-int xc,yc,r;
+void
+circle(int xc, int yc, int r)
{
if(r < 1){
point(xc, yc);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/close.c b/usr/src/ucbcmd/plot/libplot/gigi/close.c
index 9373a4729d..3a4269669e 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/close.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/close.c
@@ -1,25 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <signal.h>
#include "gigi.h"
-closepl()
+void
+closepl(void)
{
/* recieve interupts */
signal(SIGINT, SIG_IGN);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/cont.c b/usr/src/ucbcmd/plot/libplot/gigi/cont.c
index 8005fd1f97..9db4464c2d 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/cont.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-cont(xi,yi)
-int xi,yi;
+void
+cont(int xi, int yi)
{
currentx = xsc(xi);
currenty = ysc(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/dot.c b/usr/src/ucbcmd/plot/libplot/gigi/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/erase.c b/usr/src/ucbcmd/plot/libplot/gigi/erase.c
index d50da21696..8bb79f5d24 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/erase.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-erase()
+void
+erase(void)
{
printf("S(E)");
}
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/label.c b/usr/src/ucbcmd/plot/libplot/gigi/label.c
index e5f0a28a8d..cd1d86cd35 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/label.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/label.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-label(s)
-char *s;
+void
+label(char *s)
{
printf("T(S0 H2 D0 I0) \"");
for(;*s!='\0';s++) {
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/line.c b/usr/src/ucbcmd/plot/libplot/gigi/line.c
index 61aca3c623..8a8dbd3158 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/line.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/line.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-line(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+line(int x0, int y0, int x1, int y1)
{
if(xsc(x0)==currentx && ysc(y0)==currenty)
cont(x1,y1);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/linemod.c b/usr/src/ucbcmd/plot/libplot/gigi/linemod.c
index dc7b011937..dc9e7b7987 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/linemod.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-linemod( line )
-char *line;
+void
+linemod(char *line)
{
/*
* Note that the bit patterns could be compacted using the
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/move.c b/usr/src/ucbcmd/plot/libplot/gigi/move.c
index d575ff6aa0..c041491950 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/move.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/move.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-move(xi,yi)
-int xi,yi;
+void
+move(int xi, int yi)
{
currentx = xsc(xi);
currenty = ysc(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/open.c b/usr/src/ucbcmd/plot/libplot/gigi/open.c
index 7f23b8479e..8ad78739de 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/open.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/open.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Displays plot files on a gigi "graphics" terminal.
@@ -30,7 +28,8 @@ double lowy = 0.0;
double scalex = 1.0;
double scaley = 1.0;
-openpl()
+void
+openpl(void)
{
void closepl();
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/point.c b/usr/src/ucbcmd/plot/libplot/gigi/point.c
index f9579ce205..cc42e1f932 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/point.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/point.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-point(xi,yi)
-int xi,yi;
+void
+point(int xi, int yi)
{
if(xsc(xi)!=currentx || ysc(yi)!=currenty)
move(xi,yi);
diff --git a/usr/src/ucbcmd/plot/libplot/gigi/space.c b/usr/src/ucbcmd/plot/libplot/gigi/space.c
index ea3ed79b6b..d2c6e10a3a 100644
--- a/usr/src/ucbcmd/plot/libplot/gigi/space.c
+++ b/usr/src/ucbcmd/plot/libplot/gigi/space.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "gigi.h"
-space(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+space(int x0, int y0, int x1, int y1)
{
lowx = x0;
lowy = y0;
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/arc.c b/usr/src/ucbcmd/plot/libplot/hp2648/arc.c
index 6380a8ae49..dccf2956b9 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/arc.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-arc(xcent,ycent,xbeg,ybeg,xend,yend)
-int xcent,ycent,xbeg,ybeg,xend,yend;
+void
+arc(int xcent, int ycent, int xbeg, int ybeg, int xend, int yend)
{
double costheta,sintheta,x,y,xn,r;
double x1,y1,x2,y2;
@@ -50,8 +48,8 @@ int xcent,ycent,xbeg,ybeg,xend,yend;
} while( crosspflag == 0 || crossp >0);
}
-cross_product(x1,y1,x2,y2,x3,y3)
-double x1,x2,x3,y1,y2,y3;
+int
+cross_product(double x1, double y1, double x2, double y2, double x3, double y3)
{
double z,a,b;
a = (y3-y2)*(x2-x1);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/box.c b/usr/src/ucbcmd/plot/libplot/hp2648/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/box.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/circle.c b/usr/src/ucbcmd/plot/libplot/hp2648/circle.c
index 692e3302fc..6a56f8f262 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/circle.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-circle (xc,yc,r)
-int xc,yc,r;
+void
+circle(int xc, int yc, int r)
{
double costheta,sintheta,x,y,xn;
int xi,yi;
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/close.c b/usr/src/ucbcmd/plot/libplot/hp2648/close.c
index f364793348..fb66e77017 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/close.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/close.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-closepl()
+void
+closepl(void)
{
putchar('Z');
fflush(stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/cont.c b/usr/src/ucbcmd/plot/libplot/hp2648/cont.c
index 84ca2d0000..a86471858a 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/cont.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-cont(xi,yi)
-int xi,yi;
+void
+cont(int xi, int yi)
{
char xb1,xb2,yb1,yb2;
itoa(xsc(xi),&xb1,&xb2);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/dot.c b/usr/src/ucbcmd/plot/libplot/hp2648/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/erase.c b/usr/src/ucbcmd/plot/libplot/hp2648/erase.c
index 15aeb53aad..d8b071934b 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/erase.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-erase()
+void
+erase(void)
{
buffready(8);
putchar(ESC);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/label.c b/usr/src/ucbcmd/plot/libplot/hp2648/label.c
index fec2cbd916..e09d7adcf2 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/label.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/label.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-label(s)
-char *s;
+void
+label(char *s)
{
handshake();
putchar(ESC);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/line.c b/usr/src/ucbcmd/plot/libplot/hp2648/line.c
index c9ae574e8f..8c3594d5dc 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/line.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/line.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-line(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+line(int x0, int y0, int x1, int y1)
{
if(xsc(x0)==currentx && ysc(y0)==currenty)
cont(x1,y1);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/linemod.c b/usr/src/ucbcmd/plot/libplot/hp2648/linemod.c
index 8ab4fcd1d9..34a445cc08 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/linemod.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-linemod( line )
-char *line;
+void
+linemod(char *line)
{
putchar('Z');
handshake();
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/move.c b/usr/src/ucbcmd/plot/libplot/hp2648/move.c
index 25864e3f00..77b6704150 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/move.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/move.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-move(xi,yi)
-int xi,yi;
+void
+move(int xi, int yi)
{
char xb1,xb2,yb1,yb2;
itoa(xsc(xi),&xb1,&xb2);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/open.c b/usr/src/ucbcmd/plot/libplot/hp2648/open.c
index 51aa8a8c92..16c1b2f9a2 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/open.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/open.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <sgtty.h>
#include "hp2648.h"
@@ -30,7 +28,8 @@ float scalex;
float scaley;
struct sgttyb sarg;
-openpl()
+void
+openpl(void)
{
if ( isatty(fileno( stdout )) ) {
shakehands = TRUE;
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/point.c b/usr/src/ucbcmd/plot/libplot/hp2648/point.c
index 7cca9c5de5..86fd85bbe1 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/point.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/point.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-point(xi,yi)
-int xi,yi;
+void
+point(int xi, int yi)
{
if(xsc(xi)!=currentx || ysc(yi)!=currenty)
move(xi,yi);
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/space.c b/usr/src/ucbcmd/plot/libplot/hp2648/space.c
index 9524781d6a..85b143fd8a 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/space.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/space.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp2648.h"
-space(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+space(int x0, int y0, int x1, int y1)
{
lowx = x0;
lowy = y0;
diff --git a/usr/src/ucbcmd/plot/libplot/hp2648/subr.c b/usr/src/ucbcmd/plot/libplot/hp2648/subr.c
index 3fecfb3922..49dd34a28e 100644
--- a/usr/src/ucbcmd/plot/libplot/hp2648/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/hp2648/subr.c
@@ -1,25 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <sgtty.h>
#include "hp2648.h"
-handshake()
+void
+handshake(void)
{
int i;
char ch;
@@ -42,8 +41,8 @@ handshake()
}
}
-buffready(n)
-int n;
+void
+buffready(int n)
{
buffcount = buffcount + n;
if(buffcount >= 80){
@@ -56,9 +55,8 @@ int n;
}
}
-itoa(num,byte1,byte2)
-int num;
-char *byte1,*byte2;
+void
+itoa(int num, char *byte1, char *byte2)
{
*byte1 = (num & 037) | 040;
*byte2 = ((num>>5) & 037) | 040;
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/arc.c b/usr/src/ucbcmd/plot/libplot/hp7221/arc.c
index 1ad9cb2c46..eca4bbce1f 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/arc.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
@@ -34,8 +32,8 @@
#define side(x,y) (a*(x)+b*(y)+c > 0.0 ? 1 : -1)
-arc(xcent,ycent,xbeg,ybeg,xend,yend)
-int xcent,ycent,xbeg,ybeg,xend,yend;
+void
+arc(int xcent, int ycent, int xbeg, int ybeg, int xend, int yend)
{
double radius2, c2;
double a,b,c;
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/box.c b/usr/src/ucbcmd/plot/libplot/hp7221/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/box.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/circle.c b/usr/src/ucbcmd/plot/libplot/hp7221/circle.c
index 18630d286e..723e3ba807 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/circle.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-circle (xc,yc,r)
- int xc,yc,r;
+void
+circle(int xc, int yc, int r)
{
if( r < 1 ) {
point( xc, yc );
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/close.c b/usr/src/ucbcmd/plot/libplot/hp7221/close.c
index 4e7aa04437..8706e39590 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/close.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/close.c
@@ -1,25 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <signal.h>
#include "hp7221.h"
-closepl()
+void
+closepl(void)
{
/* receive interupts */
signal(SIGINT, SIG_IGN);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/cont.c b/usr/src/ucbcmd/plot/libplot/hp7221/cont.c
index 240655ae9f..7ac65beb43 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/cont.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-cont(xi,yi)
-int xi,yi;
+void
+cont(int xi, int yi)
{
currentx = scaleX(xi);
currenty = scaleY(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/dot.c b/usr/src/ucbcmd/plot/libplot/hp7221/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/erase.c b/usr/src/ucbcmd/plot/libplot/hp7221/erase.c
index f255de3efd..bd3cd83a09 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/erase.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-erase(){
+void
+erase(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/label.c b/usr/src/ucbcmd/plot/libplot/hp7221/label.c
index 19434255a7..487f620c2f 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/label.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/label.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-label(s)
-char *s;
+void
+label(char *s)
{
printf("~'%s", s);
putchar( ENDOFSTRING );
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/line.c b/usr/src/ucbcmd/plot/libplot/hp7221/line.c
index 75f35abc4c..6251f0a110 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/line.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/line.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-line(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+line(int x0, int y0, int x1, int y1)
{
if(scaleX(x0)==currentx && scaleY(y0)==currenty)
cont(x1,y1);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/linemod.c b/usr/src/ucbcmd/plot/libplot/hp7221/linemod.c
index f950e8d4ef..04504fade8 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/linemod.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-linemod( line )
-char *line;
+void
+linemod(char *line)
{
/*
* Note that the bit patterns could be compacted using the
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/move.c b/usr/src/ucbcmd/plot/libplot/hp7221/move.c
index 9cd6d103e3..e683009d77 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/move.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/move.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-move(xi,yi)
-int xi,yi;
+void
+move(int xi, int yi)
{
currentx = scaleX(xi);
currenty = scaleY(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/open.c b/usr/src/ucbcmd/plot/libplot/hp7221/open.c
index a64280367f..4a15edec0d 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/open.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/open.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Displays plot files on an HP7221 plotter.
@@ -33,7 +31,8 @@ double lowx = 0.0;
double lowy = 0.0;
double scale = 1.0;
-openpl()
+void
+openpl(void)
{
void closepl();
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/point.c b/usr/src/ucbcmd/plot/libplot/hp7221/point.c
index c5a4d12a15..3d02b6bb36 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/point.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/point.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-point(xi,yi)
-int xi,yi;
+void
+point(int xi, int yi)
{
if(scaleX(xi)!=currentx || scaleY(yi)!=currenty)
move(xi,yi);
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/space.c b/usr/src/ucbcmd/plot/libplot/hp7221/space.c
index 9792bbcc1b..0b7b0364b3 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/space.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/space.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-space(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+void
+space(int x0, int y0, int x1, int y1)
{
double scalex, scaley;
lowx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/hp7221/subr.c b/usr/src/ucbcmd/plot/libplot/hp7221/subr.c
index 74f3d407fb..ee71a44c7c 100644
--- a/usr/src/ucbcmd/plot/libplot/hp7221/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/hp7221/subr.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "hp7221.h"
-putMBP( x, y )
- int x, y;
+void
+putMBP(int x, int y)
{
int chr;
@@ -50,8 +48,8 @@ putMBP( x, y )
return;
}
-putMBN( i )
- int i;
+void
+putMBN(int i)
{
int chr;
@@ -71,8 +69,8 @@ putMBN( i )
return;
}
-putSBN( i )
- int i;
+void
+putSBN(int i)
{
i &= 077;
if ( i < 32 ) {
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/arc.c b/usr/src/ucbcmd/plot/libplot/imagen/arc.c
index 35e2d3f440..25bb2aebd2 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/arc.c
@@ -1,26 +1,30 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
int del = 20;
-step(d){
+
+void
+step(int d)
+{
del = d;
}
-arc(x,y,x0,y0,x1,y1){
+
+void
+arc(int x, int y, int x0, int y0, int x1, int y1)
+{
double pc;
double sqrt();
int flg,m,xc,yc,xs,ys,qs,qf;
@@ -111,7 +115,10 @@ arc(x,y,x0,y0,x1,y1){
}
}
}
-quad(x,y,xp,yp){
+
+int
+quad(int x,int y,int xp,int yp)
+{
if(x < xp)
if(y <= yp)return(1);
else return(4);
@@ -121,7 +128,10 @@ quad(x,y,xp,yp){
else if(y < yp)return(2);
else return(4);
}
-abs(a){
+
+int
+abs(int a)
+{
if(a < 0)return(-a);
return(a);
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/box.c b/usr/src/ucbcmd/plot/libplot/imagen/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/box.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/charset.c b/usr/src/ucbcmd/plot/libplot/imagen/charset.c
index 5beefed61a..6e373812ae 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/charset.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/charset.c
@@ -1,21 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imp.h"
+
char *imP_charset = "cour07";
int imPcsize = 12;
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/circle.c b/usr/src/ucbcmd/plot/libplot/imagen/circle.c
index 45bbe8bdf5..12666d94da 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/circle.c
@@ -1,21 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle(x,y,r){
+void
+circle(int x, int y, int r)
+{
arc(x,y,x+r,y,x+r,y);
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/close.c b/usr/src/ucbcmd/plot/libplot/imagen/close.c
index d5c38e003b..4c8be4c16a 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/close.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/close.c
@@ -1,25 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imp.h"
#include "imPcodes.h"
-closepl(){
+void
+closepl(void)
+{
putch(imP_ENDPAGE);
fflush(stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/cont.c b/usr/src/ucbcmd/plot/libplot/imagen/cont.c
index f1d0c783d1..d4d86c2e14 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/cont.c
@@ -1,25 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include "imp.h"
-cont(x,y){
+void
+cont(int x, int y)
+{
line(imPx, imPy, x, y);
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/dot.c b/usr/src/ucbcmd/plot/libplot/imagen/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/erase.c b/usr/src/ucbcmd/plot/libplot/imagen/erase.c
index 7e6403fe48..a5e57b43b0 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/erase.c
@@ -1,24 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imPcodes.h"
#include "imp.h"
-erase(){
+
+void
+erase(void)
+{
int i;
putch(imP_ENDPAGE);
imPx = imPy = 0;
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/label.c b/usr/src/ucbcmd/plot/libplot/imagen/label.c
index a25b4711ae..373f60c3b4 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/label.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/label.c
@@ -1,28 +1,28 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imPcodes.h"
#include "imp.h"
-extern imPcsize;
-label(s)
-char *s;
+
+extern int imPcsize;
+
+void
+label(char *s)
{
- register i,c;
+ int i,c;
putch(imP_SET_ABS_H);
putwd((int)((imPx-obotx)*scalex+botx)-imPcsize/2);
putch(imP_SET_ABS_V);
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/line.c b/usr/src/ucbcmd/plot/libplot/imagen/line.c
index 0a90fa6a57..f6d6081298 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/line.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/line.c
@@ -1,30 +1,34 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imp.h"
#include "imPcodes.h"
+
float obotx = 0.;
float oboty = 0.;
float botx = 2.;
float boty = 2.;
float scalex = 1.;
float scaley = 1.;
-line(x0,y0,x1,y1)
+
+void putch(int);
+void putwd(int);
+
+void
+line(int x0, int y0, int x1, int y1)
{
putch(imP_CREATE_PATH);
putwd(2); /* two coordinates follow */
@@ -37,11 +41,15 @@ line(x0,y0,x1,y1)
imPx = x1;
imPy = y1;
}
-putch(c)
+
+void
+putch(int c)
{
putc(c, stdout);
}
-putwd(w)
+
+void
+putwd(int w)
{
putch(w>>8);
putch(w);
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/linemod.c b/usr/src/ucbcmd/plot/libplot/imagen/linemod.c
index 9ba7b31ef9..7071d42fca 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/linemod.c
@@ -1,31 +1,29 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imp.h"
/*
* Hack to set font.
*/
-linemod(s)
-char *s;
+void
+linemod(char *s)
{
- register char *tit;
- register char *nam;
+ char *tit;
+ char *nam;
int siz = 0;
nam = s;
for(tit = "charset="; *tit; )
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/move.c b/usr/src/ucbcmd/plot/libplot/imagen/move.c
index ea954ebd18..14f6208efe 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/move.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/move.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imp.h"
-move(xi,yi){
+
+void
+move(int xi, int yi)
+{
imPx = xi;
imPy = yi;
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/open.c b/usr/src/ucbcmd/plot/libplot/imagen/open.c
index 4f51b9636c..4a944d1f12 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/open.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/open.c
@@ -1,25 +1,27 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "imPcodes.h"
#include "imp.h"
-openpl(){
+void setfont(char *, int);
+
+void
+openpl(void)
+{
putch(imP_SET_HV_SYSTEM);
putch((3<<3)|5);
@@ -37,7 +39,9 @@ openpl(){
putch(imP_SET_ABS_V);
putwd(0);
}
-setfont(c, sz) char *c; int sz;
+
+void
+setfont(char *c, int sz)
{
imPcsize = sz;
putch(imP_CREATE_FAMILY_TABLE);
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/point.c b/usr/src/ucbcmd/plot/libplot/imagen/point.c
index 21e7bde131..93f7313603 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/point.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/point.c
@@ -1,21 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-point(xi,yi){
+void
+point(int xi, int yi)
+{
line(xi,yi,xi,yi);
}
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/scale.c b/usr/src/ucbcmd/plot/libplot/imagen/scale.c
index 5311f551fe..c7f7011427 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/scale.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/scale.c
@@ -1,27 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
extern float scalex;
extern float scaley;
extern int scaleflag;
-scale(i,x,y)
-char i;
-float x,y;
+
+void
+scale(char i, float x, float y)
{
switch(i) {
default:
diff --git a/usr/src/ucbcmd/plot/libplot/imagen/space.c b/usr/src/ucbcmd/plot/libplot/imagen/space.c
index cf600c906a..a82d988c35 100644
--- a/usr/src/ucbcmd/plot/libplot/imagen/space.c
+++ b/usr/src/ucbcmd/plot/libplot/imagen/space.c
@@ -1,20 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
extern float botx;
extern float boty;
@@ -24,9 +22,11 @@ extern float scalex;
extern float scaley;
int PlotRes = DEFRES;
-
int scaleflag;
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = 2.;
boty = 2.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/plot/arc.c b/usr/src/ucbcmd/plot/libplot/plot/arc.c
index 91ef25c467..0dc832f491 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/arc.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-arc(xi,yi,x0,y0,x1,y1){
+
+void
+arc(int xi, int yi, int x0, int y0, int x1, int y1)
+{
putc('a',stdout);
putsi(xi);
putsi(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/box.c b/usr/src/ucbcmd/plot/libplot/plot/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/box.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/circle.c b/usr/src/ucbcmd/plot/libplot/plot/circle.c
index f32522b9c8..577c0d8a53 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/circle.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-circle(x,y,r){
+
+void
+circle(int x, int y, int r)
+{
putc('c',stdout);
putsi(x);
putsi(y);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/close.c b/usr/src/ucbcmd/plot/libplot/plot/close.c
index fd34f94b2b..1ad5004c25 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/close.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/close.c
@@ -1,25 +1,29 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-closevt(){
+
+void
+closevt(void)
+{
fflush(stdout);
}
-closepl(){
+
+void
+closepl(void)
+{
fflush(stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/plot/cont.c b/usr/src/ucbcmd/plot/libplot/plot/cont.c
index 970e6d5803..02a8b46c1d 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/cont.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/cont.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-cont(xi,yi){
+
+void
+cont(int xi, int yi)
+{
putc('n',stdout);
putsi(xi);
putsi(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/dot.c b/usr/src/ucbcmd/plot/libplot/plot/dot.c
index 8fb1610972..5199bf1355 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/dot.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-dot(xi,yi,dx,n,pat)
-int pat[];
+
+void
+dot(int xi, int yi, int dx, int n, int pat[])
{
int i;
putc('d',stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/erase.c b/usr/src/ucbcmd/plot/libplot/plot/erase.c
index 059fe9aae1..7c7b3fff56 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/erase.c
@@ -1,22 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-erase(){
+
+void
+erase(void)
+{
putc('e',stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/plot/label.c b/usr/src/ucbcmd/plot/libplot/plot/label.c
index cd345bf74d..c7e5909057 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/label.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/label.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-label(s)
-char *s;
+
+void
+label(char *s)
{
int i;
putc('t',stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/line.c b/usr/src/ucbcmd/plot/libplot/plot/line.c
index 7885631956..5d0f1d4c9b 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/line.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/line.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-line(x0,y0,x1,y1){
+
+void
+line(int x0, int y0, int x1, int y1)
+{
putc('l',stdout);
putsi(x0);
putsi(y0);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/linmod.c b/usr/src/ucbcmd/plot/libplot/plot/linmod.c
index e5906e292e..5dc22da8af 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/linmod.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/linmod.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-linemod(s)
-char *s;
+
+void
+linemod(char *s)
{
int i;
putc('f',stdout);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/move.c b/usr/src/ucbcmd/plot/libplot/plot/move.c
index 06f3456f4d..4b124fead7 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/move.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/move.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-move(xi,yi){
+
+void
+move(int xi,int yi)
+{
putc('m',stdout);
putsi(xi);
putsi(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/open.c b/usr/src/ucbcmd/plot/libplot/plot/open.c
index fbfa68f015..c06291892b 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/open.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/open.c
@@ -1,22 +1,25 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
-
-openvt(){
+void
+openvt(void)
+{
}
-openpl(){
+
+void
+openpl(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/plot/point.c b/usr/src/ucbcmd/plot/libplot/plot/point.c
index 2d515b7f25..05cb1b9f9c 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/point.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/point.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-point(xi,yi){
+
+void
+point(int xi, int yi)
+{
putc('p',stdout);
putsi(xi);
putsi(yi);
diff --git a/usr/src/ucbcmd/plot/libplot/plot/putsi.c b/usr/src/ucbcmd/plot/libplot/plot/putsi.c
index 04364105ab..611ede8679 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/putsi.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/putsi.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-putsi(a){
+
+void
+putsi(int a)
+{
putc((char)a,stdout);
putc((char)(a>>8),stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/plot/space.c b/usr/src/ucbcmd/plot/libplot/plot/space.c
index ca4f8693e9..331b314871 100644
--- a/usr/src/ucbcmd/plot/libplot/plot/space.c
+++ b/usr/src/ucbcmd/plot/libplot/plot/space.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
putc('s',stdout);
putsi(x0);
putsi(y0);
diff --git a/usr/src/ucbcmd/plot/libplot/t300/arc.c b/usr/src/ucbcmd/plot/libplot/t300/arc.c
index a4d5e23fde..ec22670932 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/arc.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-arc(){
+void
+arc(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/box.c b/usr/src/ucbcmd/plot/libplot/t300/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/box.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/t300/circle.c b/usr/src/ucbcmd/plot/libplot/t300/circle.c
index bb9a06ff21..1baa52d770 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/circle.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle(){
+void
+circle(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/close.c b/usr/src/ucbcmd/plot/libplot/t300/close.c
index cfbbcbf520..b4933198f8 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/close.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/close.c
@@ -1,26 +1,32 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-closevt(){
+
+void closepl(void);
+
+void
+closevt(void)
+{
closepl();
}
-closepl(){
+
+void
+closepl(void)
+{
fflush(stdout);
reset();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/dot.c b/usr/src/ucbcmd/plot/libplot/t300/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/erase.c b/usr/src/ucbcmd/plot/libplot/t300/erase.c
index 44fbab553e..7844a26b5b 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/erase.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-erase(){
+
+void
+erase(void)
+{
int i;
for(i=0; i<11*(VERTRESP/VERTRES); i++)
spew(DOWN);
diff --git a/usr/src/ucbcmd/plot/libplot/t300/label.c b/usr/src/ucbcmd/plot/libplot/t300/label.c
index 4bd61984a6..93ac6c3d54 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/label.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/label.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-label(s)
-char *s;
+
+void
+label(char *s)
{
int i,c;
while((c = *s++) != '\0'){
diff --git a/usr/src/ucbcmd/plot/libplot/t300/line.c b/usr/src/ucbcmd/plot/libplot/t300/line.c
index 9cca61858e..12ad44b695 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/line.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/line.c
@@ -1,31 +1,40 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-line(x0,y0,x1,y1){
+
+void iline(int, int, int, int);
+
+void
+line(int x0, int y0, int x1, int y1)
+{
iline(xconv(xsc(x0)),yconv(ysc(y0)),xconv(xsc(x1)),yconv(ysc(y1)));
return;
}
-cont(x0,y0){
+
+void
+cont(int x0, int y0)
+{
iline(xnow,ynow,xconv(xsc(x0)),yconv(ysc(y0)));
return;
}
-iline(cx0,cy0,cx1,cy1){
+
+void
+iline(int cx0, int cy0, int cx1, int cy1)
+{
int maxp,tt,j,np;
char chx,chy;
float xd,yd;
diff --git a/usr/src/ucbcmd/plot/libplot/t300/linmod.c b/usr/src/ucbcmd/plot/libplot/t300/linmod.c
index 46a98ef7ff..ee4f67b863 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/linmod.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/linmod.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-linemod(){
+void
+linemod(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/move.c b/usr/src/ucbcmd/plot/libplot/t300/move.c
index 0c67496c4c..498e46d57c 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/move.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/move.c
@@ -1,22 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-move(xi,yi){
+void
+move(int xi, int yi)
+{
movep(xconv(xsc(xi)),yconv(ysc(yi)));
return;
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/open.c b/usr/src/ucbcmd/plot/libplot/t300/open.c
index ce326d4dea..f1ef292981 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/open.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/open.c
@@ -1,23 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-#
#include <sgtty.h>
+
/* gsi plotting output routines */
# define DOWN 012
# define UP 013
@@ -43,7 +41,8 @@ int xscale, xoffset, yscale;
float botx = 0., boty = 0., obotx = 0., oboty = 0.;
float scalex = 1., scaley = 1.;
-openpl ()
+void
+openpl(void)
{
int reset();
xnow = ynow = 0;
@@ -60,6 +59,8 @@ openpl ()
return;
}
-openvt(){
-openpl();
+void
+openvt(void)
+{
+ openpl();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300/point.c b/usr/src/ucbcmd/plot/libplot/t300/point.c
index f0d9baab1b..29bf980347 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/point.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/point.c
@@ -1,22 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-point(xi,yi){
+void
+point(int xi, int yi)
+{
move(xi,yi);
label(".");
return;
diff --git a/usr/src/ucbcmd/plot/libplot/t300/space.c b/usr/src/ucbcmd/plot/libplot/t300/space.c
index d8df66c6ce..b6febb8d17 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/space.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/space.c
@@ -1,25 +1,27 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
# include "con.h"
+
float deltx = 4095.;
float delty = 4095.;
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = -2047.;
boty = -2047.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/t300/subr.c b/usr/src/ucbcmd/plot/libplot/t300/subr.c
index 27b5591d8b..ab66e11146 100644
--- a/usr/src/ucbcmd/plot/libplot/t300/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/t300/subr.c
@@ -1,29 +1,32 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include "con.h"
-abval(q)
+
+void spew(int);
+
+int
+abval(int q)
{
return (q>=0 ? q : -q);
}
-xconv (xp)
+int
+xconv(int xp)
{
/* x position input is -2047 to +2047, output must be 0 to PAGSIZ*HORZRES */
xp += 2048;
@@ -31,20 +34,23 @@ xconv (xp)
return (xoffset + xp /xscale);
}
-yconv (yp)
+int
+yconv(int yp)
{
/* see description of xconv */
yp += 2048;
return (yp / yscale);
}
-inplot()
+void
+inplot(void)
{
stty(OUTF, &PTTY);
spew (ACK);
}
-outplot()
+void
+outplot(void)
{
spew(ESC);
spew(ACK);
@@ -52,24 +58,28 @@ outplot()
stty(OUTF, &ITTY);
}
-spew(ch)
+void
+spew(int ch)
{
if(ch == UP)putc(ESC,stdout);
putc(ch, stdout);
}
-tobotleft ()
+void
+tobotleft(void)
{
move(-2048,-2048);
}
-reset()
+
+void
+reset(void)
{
outplot();
exit(0);
}
float
-dist2 (x1, y1, x2, y2)
+dist2(int x1, int y1, int x2, int y2)
{
float t,v;
t = x2-x1;
@@ -77,15 +87,17 @@ dist2 (x1, y1, x2, y2)
return (t*t+v*v);
}
-swap (pa, pb)
-int *pa, *pb;
+void
+swap(int *pa, int *pb)
{
int t;
t = *pa;
*pa = *pb;
*pb = t;
}
-movep (xg, yg)
+
+void
+movep(int xg, int yg)
{
int i,ch;
if((xg == xnow) && (yg == ynow))return;
@@ -118,12 +130,17 @@ movep (xg, yg)
xnow = xg; ynow = yg;
}
-xsc(xi){
+int
+xsc(int xi)
+{
int xa;
xa = (xi - obotx) * scalex + botx;
return(xa);
}
-ysc(yi){
+
+int
+ysc(int yi)
+{
int ya;
ya = (yi - oboty) *scaley +boty;
return(ya);
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/arc.c b/usr/src/ucbcmd/plot/libplot/t300s/arc.c
index a4d5e23fde..ec22670932 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/arc.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-arc(){
+void
+arc(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/box.c b/usr/src/ucbcmd/plot/libplot/t300s/box.c
index fe42272269..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/box.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/box.c
@@ -1,21 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/circle.c b/usr/src/ucbcmd/plot/libplot/t300s/circle.c
index bb9a06ff21..1baa52d770 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/circle.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle(){
+void
+circle(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/close.c b/usr/src/ucbcmd/plot/libplot/t300s/close.c
index cfbbcbf520..b4933198f8 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/close.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/close.c
@@ -1,26 +1,32 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-closevt(){
+
+void closepl(void);
+
+void
+closevt(void)
+{
closepl();
}
-closepl(){
+
+void
+closepl(void)
+{
fflush(stdout);
reset();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/dot.c b/usr/src/ucbcmd/plot/libplot/t300s/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/erase.c b/usr/src/ucbcmd/plot/libplot/t300s/erase.c
index 44fbab553e..7844a26b5b 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/erase.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-erase(){
+
+void
+erase(void)
+{
int i;
for(i=0; i<11*(VERTRESP/VERTRES); i++)
spew(DOWN);
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/label.c b/usr/src/ucbcmd/plot/libplot/t300s/label.c
index 325e4c06dd..60904ad1a2 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/label.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/label.c
@@ -1,24 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-label(s)
-char *s;
+
+void
+label(char *s)
{
int i,c;
while((c = *s++) != '\0'){
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/line.c b/usr/src/ucbcmd/plot/libplot/t300s/line.c
index 5a6179c3aa..308b696878 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/line.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/line.c
@@ -1,31 +1,40 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-line(x0,y0,x1,y1){
+
+void iline(int, int, int, int);
+
+void
+line(int x0, int y0, int x1, int y1)
+{
iline(xconv(xsc(x0)),yconv(ysc(y0)),xconv(xsc(x1)),yconv(ysc(y1)));
return;
}
-cont(x0,y0){
+
+void
+cont(int x0, int y0)
+{
iline(xnow,ynow,xconv(xsc(x0)),yconv(ysc(y0)));
return;
}
-iline(cx0,cy0,cx1,cy1){
+
+void
+iline(int cx0, int cy0, int cx1, int cy1)
+{
int maxp,tt,j,np;
char chx,chy,command;
float xd,yd;
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/linmod.c b/usr/src/ucbcmd/plot/libplot/t300s/linmod.c
index 46a98ef7ff..ee4f67b863 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/linmod.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/linmod.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-linemod(){
+void
+linemod(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/move.c b/usr/src/ucbcmd/plot/libplot/t300s/move.c
index 0c67496c4c..498e46d57c 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/move.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/move.c
@@ -1,22 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-move(xi,yi){
+void
+move(int xi, int yi)
+{
movep(xconv(xsc(xi)),yconv(ysc(yi)));
return;
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/open.c b/usr/src/ucbcmd/plot/libplot/t300s/open.c
index ce326d4dea..f1ef292981 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/open.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/open.c
@@ -1,23 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-#
#include <sgtty.h>
+
/* gsi plotting output routines */
# define DOWN 012
# define UP 013
@@ -43,7 +41,8 @@ int xscale, xoffset, yscale;
float botx = 0., boty = 0., obotx = 0., oboty = 0.;
float scalex = 1., scaley = 1.;
-openpl ()
+void
+openpl(void)
{
int reset();
xnow = ynow = 0;
@@ -60,6 +59,8 @@ openpl ()
return;
}
-openvt(){
-openpl();
+void
+openvt(void)
+{
+ openpl();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/point.c b/usr/src/ucbcmd/plot/libplot/t300s/point.c
index 65188fd162..f3d3752cd0 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/point.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/point.c
@@ -1,23 +1,24 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-point(xi,yi){
+
+void
+point(int xi, int yi)
+{
move(xi,yi);
label(".");
return;
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/space.c b/usr/src/ucbcmd/plot/libplot/t300s/space.c
index 78c1836578..586b41aef3 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/space.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/space.c
@@ -1,24 +1,27 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
+
+#include "con.h"
-# include "con.h"
float deltx = 4095.;
float delty = 4095.;
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = -2047.;
boty = -2047.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/t300s/subr.c b/usr/src/ucbcmd/plot/libplot/t300s/subr.c
index 2d54112f1c..bb191c4043 100644
--- a/usr/src/ucbcmd/plot/libplot/t300s/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/t300s/subr.c
@@ -1,29 +1,41 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include "con.h"
-abval(q)
+
+#define DOUBLE 010
+#define ADDR 0100
+#define COM 060
+#define MAXX 070
+#define MAXY 07
+#define SPACES 7
+
+extern int xnow, ynow;
+
+void spew(int);
+
+int
+abval(int q)
{
return (q>=0 ? q : -q);
}
-xconv (xp)
+int
+xconv(int xp)
{
/* x position input is -2047 to +2047, output must be 0 to PAGSIZ*HORZRES */
xp += 2048;
@@ -31,21 +43,24 @@ xconv (xp)
return (xoffset + xp /xscale);
}
-yconv (yp)
+int
+yconv(int yp)
{
/* see description of xconv */
yp += 2048;
return (yp / yscale);
}
-inplot()
+void
+inplot(void)
{
stty(OUTF, &PTTY);
spew(ESC);
spew (INPLOT);
}
-outplot()
+void
+outplot(void)
{
spew(ESC);
spew(ACK);
@@ -55,23 +70,27 @@ outplot()
stty (OUTF, &ITTY);
}
-spew(ch)
+void
+spew(int ch)
{
putc(ch, stdout);
}
-tobotleft ()
+void
+tobotleft(void)
{
move(-2048,-2048);
}
-reset()
+
+void
+reset(void)
{
outplot();
exit(0);
}
float
-dist2 (x1, y1, x2, y2)
+dist2(int x1, int y1, int x2, int y2)
{
float t,v;
t = x2-x1;
@@ -79,8 +98,8 @@ dist2 (x1, y1, x2, y2)
return (t*t+v*v);
}
-swap (pa, pb)
-int *pa, *pb;
+void
+swap(int *pa, int *pb)
{
int t;
t = *pa;
@@ -88,14 +107,9 @@ int *pa, *pb;
*pb = t;
}
-#define DOUBLE 010
-#define ADDR 0100
-#define COM 060
-#define MAXX 070
-#define MAXY 07
-extern xnow,ynow;
-#define SPACES 7
-movep(ix,iy){
+void
+movep(int ix, int iy)
+{
int dx,dy,remx,remy,pts,i;
int xd,yd;
int addr,command;
@@ -162,12 +176,18 @@ movep(ix,iy){
outplot();
return;
}
-xsc(xi){
+
+int
+xsc(int xi)
+{
int xa;
xa = (xi - obotx) * scalex + botx;
return(xa);
}
-ysc(yi){
+
+int
+ysc(int yi)
+{
int ya;
ya = (yi - oboty) *scaley +boty;
return(ya);
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/arc.c b/usr/src/ucbcmd/plot/libplot/t4013/arc.c
index 69bb6f5697..1a87b980d9 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/arc.c
@@ -1,25 +1,30 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
int del = 20;
-step(d){
+
+void
+step(int d)
+{
del = d;
}
-arc(x,y,x0,y0,x1,y1){
+
+void
+arc(int x, int y, int x0, int y0, int x1, int y1)
+{
double pc;
double sqrt();
int flg,m,xc,yc,xs,ys,qs,qf;
@@ -110,7 +115,10 @@ arc(x,y,x0,y0,x1,y1){
}
}
}
-quad(x,y,xp,yp){
+
+int
+quad(int x,int y,int xp,int yp)
+{
if(x < xp)
if(y <= yp)return(1);
else return(4);
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/box.c b/usr/src/ucbcmd/plot/libplot/t4013/box.c
index ce721eefec..57b9a92f88 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/box.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/box.c
@@ -1,22 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/circle.c b/usr/src/ucbcmd/plot/libplot/t4013/circle.c
index 45bbe8bdf5..12666d94da 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/circle.c
@@ -1,21 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-circle(x,y,r){
+void
+circle(int x, int y, int r)
+{
arc(x,y,x+r,y,x+r,y);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/close.c b/usr/src/ucbcmd/plot/libplot/t4013/close.c
index 0d1d8256e0..1d9111892d 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/close.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/close.c
@@ -1,27 +1,31 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-closevt(){
+
+void
+closevt(void)
+{
putch(037);
fflush(stdout);
}
-closepl(){
+
+void
+closepl(void)
+{
putch(037);
fflush(stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/dot.c b/usr/src/ucbcmd/plot/libplot/t4013/dot.c
index a9cf01dd0a..47521f8e66 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/dot.c
@@ -1,20 +1,20 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/erase.c b/usr/src/ucbcmd/plot/libplot/t4013/erase.c
index 9f0a75482c..4939b86ec4 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/erase.c
@@ -1,25 +1,26 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
extern int ohiy;
extern int ohix;
extern int oloy;
-erase(){
+
+void
+erase(void)
+{
int i;
putch(033);
putch(014);
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/label.c b/usr/src/ucbcmd/plot/libplot/t4013/label.c
index a4118a9e99..f53011803b 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/label.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/label.c
@@ -1,25 +1,23 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-label(s)
-char *s;
+void
+label(char *s)
{
- register i,c;
+ int i, c;
putch(037); /* alpha mode */
for(i=0; c=s[i]; i++)
putch(c);
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/line.c b/usr/src/ucbcmd/plot/libplot/t4013/line.c
index 23bc2baccf..6f349be478 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/line.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/line.c
@@ -1,22 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-line(x0,y0,x1,y1){
+void
+line(int x0, int y0, int x1, int y1)
+{
move(x0,y0);
cont(x1,y1);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/linemod.c b/usr/src/ucbcmd/plot/libplot/t4013/linemod.c
index 77d60374e4..dba9ee4758 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/linemod.c
@@ -1,23 +1,21 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-linemod(s)
-char *s;
+void
+linemod(char *s)
{
/* ignored on 4013 */
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/move.c b/usr/src/ucbcmd/plot/libplot/t4013/move.c
index a63a3f218a..0d7da25f83 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/move.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/move.c
@@ -1,22 +1,22 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
-move(xi,yi){
+void
+move(int xi, int yi)
+{
putch(035);
cont(xi,yi);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/open.c b/usr/src/ucbcmd/plot/libplot/t4013/open.c
index 3b3a6f672c..b573a91adf 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/open.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/open.c
@@ -1,22 +1,25 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-openvt ()
+#pragma ident "%Z%%M% %I% %E% SMI"
+
+void
+openvt(void)
{
}
-openpl(){
+
+void
+openpl(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/point.c b/usr/src/ucbcmd/plot/libplot/t4013/point.c
index 1e5393d5e5..0cdd3c032f 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/point.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/point.c
@@ -1,21 +1,22 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-point(xi,yi){
+#pragma ident "%Z%%M% %I% %E% SMI"
+
+void
+point(int xi, int yi)
+{
move(xi,yi);
cont(xi,yi);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/space.c b/usr/src/ucbcmd/plot/libplot/t4013/space.c
index 3bc365d8c7..1c4d3fcf9f 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/space.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/space.c
@@ -1,20 +1,19 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
+
extern float botx;
extern float boty;
extern float obotx;
@@ -22,7 +21,10 @@ extern float oboty;
extern float scalex;
extern float scaley;
extern int scaleflag;
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = 0.;
boty = 0.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/t4013/subr.c b/usr/src/ucbcmd/plot/libplot/t4013/subr.c
index 0772971b88..97f16737f8 100644
--- a/usr/src/ucbcmd/plot/libplot/t4013/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/t4013/subr.c
@@ -1,21 +1,21 @@
-/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
-/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
*/
+/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
+/* All Rights Reserved */
+
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
+#pragma ident "%Z%%M% %I% %E% SMI"
+
#include <stdio.h>
+
float obotx = 0.;
float oboty = 0.;
float botx = 0.;
@@ -27,7 +27,12 @@ int scaleflag;
int oloy = -1;
int ohiy = -1;
int ohix = -1;
-cont(x,y){
+
+void putch(int);
+
+void
+cont(int x, int y)
+{
int hix,hiy,lox,loy;
int n;
x = (x-obotx)*scalex + botx;
@@ -56,6 +61,8 @@ cont(x,y){
putch(0);
}
-putch(c){
+void
+putch(int c)
+{
putc(c,stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/arc.c b/usr/src/ucbcmd/plot/libplot/t4014/arc.c
index a5ceb326d7..2f7dd26d47 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/arc.c
@@ -19,22 +19,27 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
int del = 20;
-step(d){
+
+void
+step(int d)
+{
del = d;
}
-arc(x,y,x0,y0,x1,y1){
+
+void
+arc(int x, int y, int x0, int y0, int x1, int y1)
+{
double pc;
double sqrt();
int flg,m,xc,yc,xs,ys,qs,qf;
@@ -125,7 +130,10 @@ arc(x,y,x0,y0,x1,y1){
}
}
}
-quad(x,y,xp,yp){
+
+int
+quad(int x, int y, int xp, int yp)
+{
if(x < xp)
if(y <= yp)return(1);
else return(4);
@@ -135,7 +143,10 @@ quad(x,y,xp,yp){
else if(y < yp)return(2);
else return(4);
}
-abs(a){
+
+int
+abs(int a)
+{
if(a < 0)return(-a);
return(a);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/box.c b/usr/src/ucbcmd/plot/libplot/t4014/box.c
index 190476f237..e6ec1533c2 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/box.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/box.c
@@ -19,18 +19,18 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/circle.c b/usr/src/ucbcmd/plot/libplot/t4014/circle.c
index 78e902fc43..fb4c286bce 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/circle.c
@@ -19,17 +19,18 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-circle(x,y,r){
+void
+circle(int x, int y, int r)
+{
arc(x,y,x+r,y,x+r,y);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/close.c b/usr/src/ucbcmd/plot/libplot/t4014/close.c
index 4ae674b853..0b32917310 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/close.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/close.c
@@ -19,23 +19,28 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
-closevt(){
+
+void
+closevt(void)
+{
putch(037);
fflush(stdout);
}
-closepl(){
+
+void
+closepl(void)
+{
putch(037);
fflush(stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/dot.c b/usr/src/ucbcmd/plot/libplot/t4014/dot.c
index 06dde59777..a3ecc9bd43 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/dot.c
@@ -19,16 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/erase.c b/usr/src/ucbcmd/plot/libplot/t4014/erase.c
index dabf6915e6..1a540833cd 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/erase.c
@@ -19,22 +19,24 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
extern int ohiy;
extern int ohix;
extern int oloy;
extern int oextra;
-erase(){
+
+void
+erase(void)
+{
int i;
putch(033);
putch(014);
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/label.c b/usr/src/ucbcmd/plot/libplot/t4014/label.c
index 5534beb542..baf1efc8ea 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/label.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/label.c
@@ -19,16 +19,15 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#define N 0104
#define E 0101
@@ -36,6 +35,7 @@
#define S 0110
#define W 0102
#define SW 0112
+
/* arrange by incremental plotting that an initial
* character such as +, X, *, etc will fall
* right on the point, and undo it so that further
@@ -47,10 +47,11 @@ char lbl_mv[] = {
char lbl_umv[] = {
036,040,N,N,N,N,N,N,NE,NE,NE,NE,NE,NE,NE,NE,NE,NE,037,0
};
-label(s)
-char *s;
+
+void
+label(char *s)
{
- register i,c;
+ int i, c;
for(i=0; c=lbl_mv[i]; i++)
putch(c);
for(i=0; c=s[i]; i++)
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/line.c b/usr/src/ucbcmd/plot/libplot/t4014/line.c
index eed81a69b3..3690e9943d 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/line.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/line.c
@@ -19,18 +19,19 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-line(x0,y0,x1,y1){
+void
+line(int x0, int y0, int x1, int y1)
+{
move(x0,y0);
cont(x1,y1);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/linemod.c b/usr/src/ucbcmd/plot/libplot/t4014/linemod.c
index c1b0fcca89..04ce1f8bed 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/linemod.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/linemod.c
@@ -19,19 +19,18 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-linemod(s)
-char *s;
+void
+linemod(char *s)
{
char c;
putch(033);
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/move.c b/usr/src/ucbcmd/plot/libplot/t4014/move.c
index a9213ff592..39766abf2e 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/move.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/move.c
@@ -19,18 +19,19 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-move(xi,yi){
+void
+move(int xi, int yi)
+{
putch(035);
cont(xi,yi);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/open.c b/usr/src/ucbcmd/plot/libplot/t4014/open.c
index 3e8d5db7e9..bf989e7644 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/open.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/open.c
@@ -19,19 +19,22 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-openvt ()
+void
+openvt(void)
{
}
-openpl(){
+
+void
+openpl(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/point.c b/usr/src/ucbcmd/plot/libplot/t4014/point.c
index fd0d3df99e..a2bffdfbeb 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/point.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/point.c
@@ -19,18 +19,19 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-point(xi,yi){
+void
+point(int xi, int yi)
+{
move(xi,yi);
cont(xi,yi);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/space.c b/usr/src/ucbcmd/plot/libplot/t4014/space.c
index 812e3e5708..732920fb5b 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/space.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/space.c
@@ -19,16 +19,15 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
extern float botx;
extern float boty;
@@ -37,7 +36,10 @@ extern float oboty;
extern float scalex;
extern float scaley;
extern int scaleflag;
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = 0.;
boty = 0.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/t4014/subr.c b/usr/src/ucbcmd/plot/libplot/t4014/subr.c
index d5782701f4..0965934b57 100644
--- a/usr/src/ucbcmd/plot/libplot/t4014/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/t4014/subr.c
@@ -19,18 +19,18 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
+
float obotx = 0.;
float oboty = 0.;
float botx = 0.;
@@ -43,7 +43,12 @@ int oloy = -1;
int ohiy = -1;
int ohix = -1;
int oextra = -1;
-cont(x,y){
+
+void putch(int);
+
+void
+cont(int x, int y)
+{
int hix,hiy,lox,loy,extra;
int n;
x = (x-obotx)*scalex + botx;
@@ -85,6 +90,8 @@ cont(x,y){
putch(0);
}
-putch(c){
+void
+putch(int c)
+{
putc(c,stdout);
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/arc.c b/usr/src/ucbcmd/plot/libplot/t450/arc.c
index 8be09951b5..408fd8f923 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/arc.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/arc.c
@@ -19,16 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-arc(){
+void
+arc(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/box.c b/usr/src/ucbcmd/plot/libplot/t450/box.c
index 190476f237..e6ec1533c2 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/box.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/box.c
@@ -19,18 +19,18 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-box(x0, y0, x1, y1)
+void
+box(int x0, int y0, int x1, int y1)
{
move(x0, y0);
cont(x0, y1);
diff --git a/usr/src/ucbcmd/plot/libplot/t450/circle.c b/usr/src/ucbcmd/plot/libplot/t450/circle.c
index d29326de64..f6a0a988fd 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/circle.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/circle.c
@@ -19,16 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-circle(){
+void
+circle(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/close.c b/usr/src/ucbcmd/plot/libplot/t450/close.c
index ef9737b830..b67558c87c 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/close.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/close.c
@@ -19,22 +19,29 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
+#include <stdio.h>
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+void closepl(void);
-#include <stdio.h>
-closevt(){
+void
+closevt(void)
+{
closepl();
}
-closepl(){
+
+void
+closepl(void)
+{
fflush(stdout);
reset();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/dot.c b/usr/src/ucbcmd/plot/libplot/t450/dot.c
index 06dde59777..a3ecc9bd43 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/dot.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/dot.c
@@ -19,16 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-dot(){
+void
+dot(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/erase.c b/usr/src/ucbcmd/plot/libplot/t450/erase.c
index 969a1d5f63..961ec87d08 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/erase.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/erase.c
@@ -19,19 +19,21 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-erase(){
+
+void
+erase(void)
+{
int i;
for(i=0; i<11*(VERTRESP/VERTRES); i++)
spew(DOWN);
diff --git a/usr/src/ucbcmd/plot/libplot/t450/label.c b/usr/src/ucbcmd/plot/libplot/t450/label.c
index 0cc08977cc..abef1ac459 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/label.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/label.c
@@ -19,20 +19,20 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include "con.h"
-label(s)
-char *s;
+
+void
+label(char *s)
{
int i,c;
while((c = *s++) != '\0'){
diff --git a/usr/src/ucbcmd/plot/libplot/t450/line.c b/usr/src/ucbcmd/plot/libplot/t450/line.c
index 226fee3148..3aa35fd288 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/line.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/line.c
@@ -19,27 +19,37 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
+#include "con.h"
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+void iline(int, int, int, int);
-#include "con.h"
-line(x0,y0,x1,y1){
+void
+line(int x0, int y0, int x1, int y1)
+{
iline(xconv(xsc(x0)),yconv(ysc(y0)),xconv(xsc(x1)),yconv(ysc(y1)));
return;
}
-cont(x0,y0){
+
+void
+cont(int x0, int y0)
+{
iline(xnow,ynow,xconv(xsc(x0)),yconv(ysc(y0)));
return;
}
-iline(cx0,cy0,cx1,cy1){
+
+void
+iline(int cx0, int cy0, int cx1, int cy1)
+{
int maxp,tt,j,np;
char chx,chy;
float xd,yd;
diff --git a/usr/src/ucbcmd/plot/libplot/t450/linmod.c b/usr/src/ucbcmd/plot/libplot/t450/linmod.c
index b1731bdbe9..897c62ea19 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/linmod.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/linmod.c
@@ -19,16 +19,17 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-linemod(){
+void
+linemod(void)
+{
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/move.c b/usr/src/ucbcmd/plot/libplot/t450/move.c
index a0b158bf8d..74983e7ba4 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/move.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/move.c
@@ -19,18 +19,19 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-move(xi,yi){
+void
+move(int xi, int yi)
+{
movep(xconv(xsc(xi)),yconv(ysc(yi)));
return;
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/open.c b/usr/src/ucbcmd/plot/libplot/t450/open.c
index 6171d87d47..1e9654329e 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/open.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/open.c
@@ -19,34 +19,33 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-#
#include <sgtty.h>
+
/* gsi plotting output routines */
-# define DOWN 012
-# define UP 013
-# define LEFT 010
-# define RIGHT 040
-# define BEL 007
-# define ACK 006
+#define DOWN 012
+#define UP 013
+#define LEFT 010
+#define RIGHT 040
+#define BEL 007
+#define ACK 006
#define PLOTIN 063
#define PLOTOUT 064
-# define CR 015
-# define FF 014
-# define VERTRESP 48
-# define HORZRESP 60.
-# define HORZRES 6.
-# define VERTRES 8.
+#define CR 015
+#define FF 014
+#define VERTRESP 48
+#define HORZRESP 60.
+#define HORZRES 6.
+#define VERTRES 8.
/* down is line feed, up is reverse oyne feed,
left is bwckspace, right is space. 48 points per inch
vertically, 60 horizontally */
@@ -59,7 +58,8 @@ int xscale, xoffset, yscale;
float botx = 0., boty = 0., obotx = 0., oboty = 0.;
float scalex = 1., scaley = 1.;
-openpl ()
+void
+openpl(void)
{
int reset();
xnow = ynow = 0;
@@ -77,6 +77,8 @@ openpl ()
return;
}
-openvt(){
-openpl();
+void
+openvt(void)
+{
+ openpl();
}
diff --git a/usr/src/ucbcmd/plot/libplot/t450/point.c b/usr/src/ucbcmd/plot/libplot/t450/point.c
index 7389adde38..eea1f16f3c 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/point.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/point.c
@@ -19,18 +19,19 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
+#pragma ident "%Z%%M% %I% %E% SMI"
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
-point(xi,yi){
+void
+point(int xi, int yi)
+{
move(xi,yi);
label(".");
return;
diff --git a/usr/src/ucbcmd/plot/libplot/t450/space.c b/usr/src/ucbcmd/plot/libplot/t450/space.c
index 70f60955d4..6f0c5a2606 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/space.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/space.c
@@ -19,19 +19,21 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
# include "con.h"
-space(x0,y0,x1,y1){
+
+void
+space(int x0, int y0, int x1, int y1)
+{
botx = -2047.;
boty = -2047.;
obotx = x0;
diff --git a/usr/src/ucbcmd/plot/libplot/t450/subr.c b/usr/src/ucbcmd/plot/libplot/t450/subr.c
index 05fb7841a7..3f491c6705 100644
--- a/usr/src/ucbcmd/plot/libplot/t450/subr.c
+++ b/usr/src/ucbcmd/plot/libplot/t450/subr.c
@@ -19,25 +19,29 @@
*
* CDDL HEADER END
*/
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
+#pragma ident "%Z%%M% %I% %E% SMI"
#include <stdio.h>
#include "con.h"
-abval(q)
+
+void spew(int);
+
+int
+abval(int q)
{
return (q>=0 ? q : -q);
}
-xconv (xp)
+int
+xconv(int xp)
{
/* x position input is -2047 to +2047, output must be 0 to PAGSIZ*HORZRES */
xp += 2048;
@@ -45,27 +49,31 @@ xconv (xp)
return (xoffset + xp /xscale);
}
-yconv (yp)
+int
+yconv(int yp)
{
/* see description of xconv */
yp += 2048;
return (yp / yscale);
}
-inplot()
+void
+inplot(void)
{
spew (ESC);
spew(PLOTIN);
}
-outplot()
+void
+outplot(void)
{
spew(ESC);
spew(PLOTOUT);
fflush(stdout);
}
-spew(ch)
+void
+spew(int ch)
{
if(ch == UP){
putc(ESC,stdout);
@@ -74,11 +82,14 @@ spew(ch)
putc(ch, stdout);
}
-tobotleft ()
+void
+tobotleft(void)
{
move(-2048,-2048);
}
-reset()
+
+void
+reset(void)
{
signal(2,1);
outplot();
@@ -87,7 +98,7 @@ reset()
}
float
-dist2 (x1, y1, x2, y2)
+dist2(int x1, int y1, int x2, int y2)
{
float t,v;
t = x2-x1;
@@ -95,15 +106,17 @@ dist2 (x1, y1, x2, y2)
return (t*t+v*v);
}
-swap (pa, pb)
-int *pa, *pb;
+void
+swap(int *pa, int *pb)
{
int t;
t = *pa;
*pa = *pb;
*pb = t;
}
-movep (xg,yg)
+
+void
+movep(int xg, int yg)
{
int i,ch;
if((xg == xnow) && (yg == ynow))return;
@@ -136,12 +149,17 @@ movep (xg,yg)
xnow = xg; ynow = yg;
}
-xsc(xi){
+int
+xsc(int xi)
+{
int xa;
xa = (xi - obotx) * scalex + botx;
return(xa);
}
-ysc(yi){
+
+int
+ysc(int yi)
+{
int ya;
ya = (yi - oboty) *scaley +boty;
return(ya);
diff --git a/usr/src/ucbcmd/plot/plottoa.c b/usr/src/ucbcmd/plot/plottoa.c
index 9f74001372..d66db8ca12 100644
--- a/usr/src/ucbcmd/plot/plottoa.c
+++ b/usr/src/ucbcmd/plot/plottoa.c
@@ -1,21 +1,18 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
-
/*
* Copyright (c) 1980 Regents of the University of California.
* All rights reserved. The Berkeley software License Agreement
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Convert the standard plot input into a readable form for debugging.
@@ -26,8 +23,25 @@
float deltx;
float delty;
-main(argc, argv)
-char **argv;
+static void arc(int, int, int, int, int, int);
+static void circle(int, int, int);
+static void closepl(void);
+static void cont(int, int);
+static void dot(int, int, int, int, char *);
+static void erase(void);
+static void fplt(FILE *);
+static int getsi(FILE *);
+static void getstr(char *, FILE *);
+static void label(char *);
+static void line(int, int, int, int);
+static void linemod(char *);
+static void move(int, int);
+static void openpl(void);
+static void point(int, int);
+static void space(int, int, int, int);
+
+int
+main(int argc, char **argv)
{
int std=1;
FILE *fin;
@@ -55,12 +69,12 @@ char **argv;
}
if (std)
fplt( stdin );
- exit(0);
+ return (0);
}
-fplt(fin)
-FILE *fin;
+static void
+fplt(FILE *fin)
{
int c;
char s[256];
@@ -131,7 +145,7 @@ FILE *fin;
dx = getsi(fin);
n = getsi(fin);
for(i=0; i<n; i++)pat[i] = getsi(fin);
- dot(xi,yi,dx,n,pat);
+ dot(xi, yi, dx, n, (char *)pat);
break;
}
}
@@ -139,8 +153,8 @@ FILE *fin;
}
/* get an integer stored in 2 ascii bytes. */
-getsi(fin)
-FILE *fin;
+static int
+getsi(FILE *fin)
{
short a, b;
if((b = getc(fin)) == EOF)
@@ -151,9 +165,8 @@ FILE *fin;
return(a|b);
}
-getstr(s,fin)
-char *s;
-FILE *fin;
+static void
+getstr(char *s, FILE *fin)
{
for( ; *s = getc(fin); s++)
if(*s == '\n')
@@ -163,78 +176,80 @@ FILE *fin;
/* Print out the arguments to plot routines. */
-space(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+static void
+space(int x0, int y0, int x1, int y1)
{
printf( "s %d %d %d %d\n", x0, y0, x1, y1 );
}
-openpl()
+static void
+openpl(void)
{
}
-closepl()
+static void
+closepl(void)
{
}
-erase()
+static void
+erase(void)
{
printf( "e\n" );
}
-move(xi,yi)
-int xi,yi;
+static void
+move(int xi, int yi)
{
printf( "m %d %d\n", xi, yi );
}
-cont(xi,yi)
-int xi,yi;
+static void
+cont(int xi, int yi)
{
printf( "n %d %d\n", xi, yi );
}
-line(x0,y0,x1,y1)
-int x0,y0,x1,y1;
+static void
+line(int x0, int y0, int x1, int y1)
{
printf( "l %d %d %d %d\n", x0, y0, x1, y1 );
}
-point(xi,yi)
-int xi,yi;
+static void
+point(int xi, int yi)
{
printf( "p %d %d\n", xi, yi );
}
-label(s)
-char *s;
+static void
+label(char *s)
{
printf( "t%s\n\n", s );
}
-arc(xcent,ycent,xbeg,ybeg,xend,yend)
-int xcent,ycent,xbeg,ybeg,xend,yend;
+static void
+arc(int xcent, int ycent, int xbeg, int ybeg, int xend, int yend)
{
printf( "a %d %d %d %d %d %d\n", xcent, ycent, xbeg, ybeg, xend, yend );
}
-circle (xc,yc,r)
-int xc,yc,r;
+static void
+circle(int xc, int yc, int r)
{
printf( "c %d %d %d\n", xc, yc, r );
}
-linemod( line )
-char *line;
+static void
+linemod(char *line)
{
printf( "f%s\n\n", line );
}
/* don't know what this should do */
-dot(xi,yi,dx,n,pat)
-int xi,yi,dx,n;
-char *pat;
+static void
+dot(int xi, int yi, int dx, int n, char *pat)
{
printf("d %d %d %d %d %s\n\n", xi, yi, dx, n, pat);
}
diff --git a/usr/src/ucbcmd/plot/vplot.c b/usr/src/ucbcmd/plot/vplot.c
index 0bf0935595..d7902f1b32 100644
--- a/usr/src/ucbcmd/plot/vplot.c
+++ b/usr/src/ucbcmd/plot/vplot.c
@@ -1,9 +1,10 @@
+/*
+ * Copyright 2005 Sun Microsystems, Inc. All rights reserved.
+ * Use is subject to license terms.
+ */
+
/* Copyright (c) 1984, 1986, 1987, 1988, 1989 AT&T */
/* All Rights Reserved */
-
-
-#ident "%Z%%M% %I% %E% SMI" /* SVr4.0 1.1 */
-
/*
* Copyright (c) 1980 Regents of the University of California.
@@ -11,11 +12,7 @@
* specifies the terms and conditions for redistribution.
*/
-/*
- * Copyright (c) 1983, 1984 1985, 1986, 1987, 1988, Sun Microsystems, Inc.
- * All Rights Reserved.
- */
-
+#pragma ident "%Z%%M% %I% %E% SMI"
/*
* Reads standard graphics input and produces a plot on the
@@ -80,12 +77,19 @@ struct dispatch dispatch[256];
char *bits;
char *fontFile = "/usr/lib/vfont/R.6";
-main(argc, argv)
-int argc;
-char **argv;
+static void circle(int, int, int);
+static int getinteger(FILE *);
+static int getpict(void);
+static void InitFont(void);
+static void line(int, int, int, int);
+static void plotch(char);
+static void point(int, int);
+
+int
+main(int argc, char **argv)
{
- register char *cp1, *arg;
- register i;
+ char *cp1, *arg;
+ int i;
int again;
infile = stdin;
@@ -172,11 +176,15 @@ char **argv;
execv(LPR, lpargs);
fprintf(stderr, "can't exec %s\n", LPR);
cleanup();
+
+ /* NOTREACHED */
+ return (0);
}
-getpict()
+static int
+getpict(void)
{
- register x1, y1;
+ int x1, y1;
for (;;) switch (x1 = getc(infile)) {
@@ -322,11 +330,11 @@ getpict()
}
}
-plotch(ch)
-char ch;
+static void
+plotch(char ch)
{
- register int i,j,k;
- register char *ptr,c;
+ int i,j,k;
+ char *ptr,c;
int nbytes;
if (!fontSet)
@@ -349,7 +357,8 @@ char ch;
lastx += dispatch['a'].width;
}
-InitFont()
+static void
+InitFont(void)
{
char *s;
int fonts;
@@ -394,12 +403,12 @@ InitFont()
}
}
-line(x0, y0, x1, y1)
-register x0, y0;
+static void
+line(int x0, int y0, int x1, int y1)
{
int dx, dy;
int xinc, yinc;
- register res1;
+ int res1;
int res2;
int slope;
@@ -443,9 +452,10 @@ register x0, y0;
#define labs(a) (a >= 0 ? a : -a)
-circle(x,y,c)
+static void
+circle(int x, int y, int c)
{
- register dx, dy;
+ int dx, dy;
long ep;
int de;
@@ -477,15 +487,16 @@ circle(x,y,c)
* The origin is the top left-hand corner with increasing x towards the
* right and increasing y going down.
*/
-point(x, y)
-register int x, y;
+static void
+point(int x, int y)
{
- register unsigned byte;
+ unsigned byte;
byte = y * DevRange8 + (x >> 3);
if (byte < bufsize)
obuf[byte] |= 1 << (7 - (x & 07));
}
+
void
cleanup()
{
@@ -496,10 +507,10 @@ cleanup()
exit(1);
}
-getinteger(f)
-FILE *f;
+static int
+getinteger(FILE *f)
{
- register int low, high, result;
+ int low, high, result;
low = getc(f);
high = getc(f);