summaryrefslogtreecommitdiff
path: root/util.c
diff options
context:
space:
mode:
authorLarry Wall <lwall@jpl-devvax.jpl.nasa.gov>1991-01-11 08:58:45 +0000
committerLarry Wall <lwall@jpl-devvax.jpl.nasa.gov>1991-01-11 08:58:45 +0000
commit27e2fb84680b9cc1db17238d5bf10b97626f477f (patch)
tree39824ce086ad815a976233d0edef5992b06e833c /util.c
parentc623bd54707a8bf975b272e17e7c3b3342b31eb0 (diff)
downloadperl-27e2fb84680b9cc1db17238d5bf10b97626f477f.tar.gz
perl 3.0 patch #44 patch #42, continuedperl-3.044
See patch #42.
Diffstat (limited to 'util.c')
-rw-r--r--util.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/util.c b/util.c
index de8f122593..b14069411d 100644
--- a/util.c
+++ b/util.c
@@ -1,4 +1,4 @@
-/* $Header: util.c,v 3.0.1.10 90/11/10 02:19:28 lwall Locked $
+/* $Header: util.c,v 3.0.1.11 91/01/11 18:33:10 lwall Locked $
*
* Copyright (c) 1989, Larry Wall
*
@@ -6,6 +6,10 @@
* as specified in the README file that comes with the perl 3.0 kit.
*
* $Log: util.c,v $
+ * Revision 3.0.1.11 91/01/11 18:33:10 lwall
+ * patch42: die could exit with 0 value on some machines
+ * patch42: Configure checks typecasting behavior better
+ *
* Revision 3.0.1.10 90/11/10 02:19:28 lwall
* patch38: random cleanup
* patch38: sequence of s/^x//; s/x$//; could screw up malloc
@@ -855,7 +859,7 @@ long a1, a2, a3, a4;
if (e_fp)
(void)UNLINK(e_tmpname);
statusvalue >>= 8;
- exit(errno?errno:(statusvalue?statusvalue:255));
+ exit((int)((errno&255)?errno:((statusvalue&255)?statusvalue:255)));
}
/*VARARGS1*/
@@ -959,7 +963,7 @@ va_dcl
if (e_fp)
(void)UNLINK(e_tmpname);
statusvalue >>= 8;
- exit((int)(errno?errno:(statusvalue?statusvalue:255)));
+ exit((int)((errno&255)?errno:((statusvalue&255)?statusvalue:255)));
}
/*VARARGS0*/
@@ -1458,7 +1462,7 @@ double f;
{
long along;
-#ifdef mips
+#if CASTFLAGS & 2
# define BIGDOUBLE 2147483648.0
if (f >= BIGDOUBLE)
return (unsigned long)(f-(long)(f/BIGDOUBLE)*BIGDOUBLE)|0x80000000;