Date: Wed, 5 Sep 2007 16:45:00 GMT From: Xin LI <delphij@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 126089 for review Message-ID: <200709051645.l85Gj0J8066409@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=126089 Change 126089 by delphij@charlie on 2007/09/05 16:44:19 IFC Affected files ... .. //depot/projects/delphij_fork/contrib/less/main.c#4 integrate .. //depot/projects/delphij_fork/lib/libutil/expand_number.3#2 integrate .. //depot/projects/delphij_fork/lib/libutil/expand_number.c#2 integrate .. //depot/projects/delphij_fork/lib/libutil/humanize_number.3#2 integrate .. //depot/projects/delphij_fork/sys/arm/xscale/i80321/i80321.c#2 integrate Differences ... ==== //depot/projects/delphij_fork/contrib/less/main.c#4 (text+ko) ==== @@ -1,4 +1,4 @@ -/* $FreeBSD: src/contrib/less/main.c,v 1.11 2007/08/13 16:15:26 delphij Exp $ */ +/* $FreeBSD: src/contrib/less/main.c,v 1.12 2007/09/04 13:54:09 delphij Exp $ */ /* * Copyright (C) 1984-2007 Mark Nudelman * @@ -244,7 +244,7 @@ quit(QUIT_OK); } - if (missing_cap && !know_dumb) + if (missing_cap && !know_dumb && !less_is_more) error("WARNING: terminal is not fully functional", NULL_PARG); init_mark(); open_getchr(); ==== //depot/projects/delphij_fork/lib/libutil/expand_number.3#2 (text+ko) ==== @@ -23,7 +23,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $FreeBSD: src/lib/libutil/expand_number.3,v 1.1 2007/09/01 06:19:11 pjd Exp $ +.\" $FreeBSD: src/lib/libutil/expand_number.3,v 1.2 2007/09/05 14:25:16 pjd Exp $ .\" .Dd April 16, 2007 .Dt EXPAND_NUMBER 3 @@ -77,6 +77,8 @@ .It Bq Er ERANGE Result doesn't fit into 64 bits. .El +.Sh SEE ALSO +.Xr humanize_number 3 .Sh HISTORY The .Fn expand_number ==== //depot/projects/delphij_fork/lib/libutil/expand_number.c#2 (text+ko) ==== @@ -26,7 +26,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/lib/libutil/expand_number.c,v 1.1 2007/09/01 06:19:11 pjd Exp $"); +__FBSDID("$FreeBSD: src/lib/libutil/expand_number.c,v 1.2 2007/09/05 14:27:13 pjd Exp $"); #include <sys/types.h> #include <ctype.h> @@ -68,7 +68,22 @@ } s = tolower(*endptr); - for (i = 0; i < unit[i] != '\0'; i++) { + switch (s) { + case 'b': + case 'k': + case 'm': + case 'g': + case 't': + case 'p': + case 'e': + break; + default: + /* Unrecognized unit. */ + errno = EINVAL; + return (-1); + } + + for (i = 0; unit[i] != '\0'; i++) { if (s == unit[i]) break; if ((number < 0 && (number << 10) > number) || @@ -78,11 +93,6 @@ } number <<= 10; } - if (unit[i] == '\0') { - /* Unrecognized unit. */ - errno = EINVAL; - return (-1); - } *num = number; return (0); ==== //depot/projects/delphij_fork/lib/libutil/humanize_number.3#2 (text+ko) ==== @@ -1,5 +1,5 @@ .\" $NetBSD: humanize_number.3,v 1.4 2003/04/16 13:34:37 wiz Exp $ -.\" $FreeBSD: src/lib/libutil/humanize_number.3,v 1.10 2006/09/17 21:27:35 ru Exp $ +.\" $FreeBSD: src/lib/libutil/humanize_number.3,v 1.11 2007/09/05 14:25:16 pjd Exp $ .\" .\" Copyright (c) 1999, 2002 The NetBSD Foundation, Inc. .\" All rights reserved. @@ -146,6 +146,8 @@ If .Dv HN_GETSCALE is specified, the prefix index number will be returned instead. +.Sh SEE ALSO +.Xr expand_number 3 .Sh HISTORY The .Fn humanize_number ==== //depot/projects/delphij_fork/sys/arm/xscale/i80321/i80321.c#2 (text+ko) ==== @@ -40,7 +40,7 @@ */ #include <sys/cdefs.h> -__FBSDID("$FreeBSD: src/sys/arm/xscale/i80321/i80321.c,v 1.6 2006/07/25 01:08:41 kevlo Exp $"); +__FBSDID("$FreeBSD: src/sys/arm/xscale/i80321/i80321.c,v 1.7 2007/09/04 18:45:27 cognet Exp $"); #include <sys/param.h> #include <sys/systm.h> @@ -213,8 +213,6 @@ PCIM_CMD_SERRESPEN; bus_space_write_4(sc->sc_st, sc->sc_atu_sh, PCIR_COMMAND, preg); - preg = bus_space_read_4(sc->sc_st, sc->sc_atu_sh, - PCIR_COMMAND); } /* Initialize the bus space tags. */ i80321_io_bs_init(&sc->sc_pci_iot, sc);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200709051645.l85Gj0J8066409>