Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/usr.bin/xlint/lint1 -0 is not unary overflow.
details: https://anonhg.NetBSD.org/src/rev/46a9c27f4919
branches: trunk
changeset: 778297:46a9c27f4919
user: christos <christos%NetBSD.org@localhost>
date: Wed Mar 21 14:17:22 2012 +0000
description:
-0 is not unary overflow.
diffstat:
usr.bin/xlint/lint1/tree.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r 8c425db1367f -r 46a9c27f4919 usr.bin/xlint/lint1/tree.c
--- a/usr.bin/xlint/lint1/tree.c Wed Mar 21 14:11:24 2012 +0000
+++ b/usr.bin/xlint/lint1/tree.c Wed Mar 21 14:17:22 2012 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: tree.c,v 1.68 2011/02/05 17:14:14 christos Exp $ */
+/* $NetBSD: tree.c,v 1.69 2012/03/21 14:17:22 christos Exp $ */
/*
* Copyright (c) 1994, 1995 Jochen Pohl
@@ -37,7 +37,7 @@
#include <sys/cdefs.h>
#if defined(__RCSID) && !defined(lint)
-__RCSID("$NetBSD: tree.c,v 1.68 2011/02/05 17:14:14 christos Exp $");
+__RCSID("$NetBSD: tree.c,v 1.69 2012/03/21 14:17:22 christos Exp $");
#endif
#include <stdlib.h>
@@ -2676,7 +2676,7 @@
break;
case UMINUS:
q = -sl;
- if (msb(q, t, -1) == msb(sl, t, -1))
+ if (sl != 0 && msb(q, t, -1) == msb(sl, t, -1))
ovfl = 1;
break;
case COMPL:
Home |
Main Index |
Thread Index |
Old Index