summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTheo de Raadt <deraadt@cvs.openbsd.org>2006-10-03 00:49:10 +0000
committerTheo de Raadt <deraadt@cvs.openbsd.org>2006-10-03 00:49:10 +0000
commite1ca223320b5c19d983f34c51a654f11c774471a (patch)
treec54cd1f882db7dd60e7047c0fa7f93ce3d29633e
parent476c284e832c1a325a19ca10ad6aa7ffa6a8829d (diff)
strtonum() with INT_MAX intead of LONG_MAX, problem pointed out by pierre-yves@spootnik.org
-rw-r--r--usr.sbin/ntpd/parse.y4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.sbin/ntpd/parse.y b/usr.sbin/ntpd/parse.y
index 4838f255e0b..9e106415301 100644
--- a/usr.sbin/ntpd/parse.y
+++ b/usr.sbin/ntpd/parse.y
@@ -1,4 +1,4 @@
-/* $OpenBSD: parse.y,v 1.29 2006/06/01 06:06:59 otto Exp $ */
+/* $OpenBSD: parse.y,v 1.30 2006/10/03 00:49:09 deraadt Exp $ */
/*
* Copyright (c) 2002, 2003, 2004 Henning Brauer <henning@openbsd.org>
@@ -209,7 +209,7 @@ number : STRING {
u_long ulval;
const char *errstr;
- ulval = strtonum($1, 0, LONG_MAX, &errstr);
+ ulval = strtonum($1, 0, INT_MAX, &errstr);
if (errstr) {
yyerror("\"%s\" invalid: %s", $1, errstr);
free($1);