summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorArtur Grabowski <art@cvs.openbsd.org>2001-06-25 04:41:26 +0000
committerArtur Grabowski <art@cvs.openbsd.org>2001-06-25 04:41:26 +0000
commit1949c7f9a7cab4c3c7dcfcb2dd4e99c0267c6e89 (patch)
treeea8dce614c09fc35fff6e841b9017f4c637ef84f /bin
parenta6b55aee56b75d1055400f67d632d15ec1eccb70 (diff)
fix obvious warnings.
Diffstat (limited to 'bin')
-rw-r--r--bin/csh/alloc.c6
-rw-r--r--bin/csh/dol.c7
-rw-r--r--bin/csh/func.c7
3 files changed, 11 insertions, 9 deletions
diff --git a/bin/csh/alloc.c b/bin/csh/alloc.c
index cfdf31055a1..226c3a40034 100644
--- a/bin/csh/alloc.c
+++ b/bin/csh/alloc.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: alloc.c,v 1.4 1997/07/25 18:57:57 mickey Exp $ */
+/* $OpenBSD: alloc.c,v 1.5 2001/06/25 04:41:24 art Exp $ */
/* $NetBSD: alloc.c,v 1.6 1995/03/21 09:02:23 cgd Exp $ */
/*-
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)alloc.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: alloc.c,v 1.4 1997/07/25 18:57:57 mickey Exp $";
+static char rcsid[] = "$OpenBSD: alloc.c,v 1.5 2001/06/25 04:41:24 art Exp $";
#endif
#endif /* not lint */
@@ -127,5 +127,5 @@ showall(v, t)
{
memtop = (char *) sbrk(0);
(void) fprintf(cshout, "Allocated memory from 0x%lx to 0x%lx (%d).\n",
- (unsigned long) membot, (unsigned long) memtop, memtop - membot);
+ (unsigned long) membot, (unsigned long) memtop, (int)memtop - membot);
}
diff --git a/bin/csh/dol.c b/bin/csh/dol.c
index 6dd48a109bd..7ce3cd3fee2 100644
--- a/bin/csh/dol.c
+++ b/bin/csh/dol.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dol.c,v 1.5 2000/10/30 17:16:46 millert Exp $ */
+/* $OpenBSD: dol.c,v 1.6 2001/06/25 04:41:25 art Exp $ */
/* $NetBSD: dol.c,v 1.8 1995/09/27 00:38:38 jtc Exp $ */
/*-
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)dol.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: dol.c,v 1.5 2000/10/30 17:16:46 millert Exp $";
+static char rcsid[] = "$OpenBSD: dol.c,v 1.6 2001/06/25 04:41:25 art Exp $";
#endif
#endif /* not lint */
@@ -607,11 +607,12 @@ Dgetdol()
stderror(ERR_SYNTAX);
}
else {
- if (subscr > 0)
+ if (subscr > 0) {
if (subscr > upb)
lwb = 1, upb = 0;
else
lwb = upb = subscr;
+ }
unDredc(c);
}
if (dimen) {
diff --git a/bin/csh/func.c b/bin/csh/func.c
index 16641a02fa1..f2bdff7b280 100644
--- a/bin/csh/func.c
+++ b/bin/csh/func.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: func.c,v 1.9 1998/12/16 17:54:32 deraadt Exp $ */
+/* $OpenBSD: func.c,v 1.10 2001/06/25 04:41:25 art Exp $ */
/* $NetBSD: func.c,v 1.11 1996/02/09 02:28:29 christos Exp $ */
/*-
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)func.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: func.c,v 1.9 1998/12/16 17:54:32 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: func.c,v 1.10 2001/06/25 04:41:25 art Exp $";
#endif
#endif /* not lint */
@@ -767,11 +767,12 @@ getword(wp)
c = readc(1);
if (c == '\\' && (c = readc(1)) == '\n')
c = ' ';
- if (c == '\'' || c == '"')
+ if (c == '\'' || c == '"') {
if (d == 0)
d = c;
else if (d == c)
d = 0;
+ }
if (c < 0)
goto past;
if (wp) {