From owner-p4-projects@FreeBSD.ORG Fri Apr 21 18:23:37 2006 Return-Path: X-Original-To: p4-projects@freebsd.org Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id 48EC016A406; Fri, 21 Apr 2006 18:23:37 +0000 (UTC) X-Original-To: perforce@freebsd.org Delivered-To: perforce@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 1569516A401 for ; Fri, 21 Apr 2006 18:23:37 +0000 (UTC) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [216.136.204.115]) by mx1.FreeBSD.org (Postfix) with ESMTP id AB52443D48 for ; Fri, 21 Apr 2006 18:23:36 +0000 (GMT) (envelope-from imp@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.13.1/8.13.1) with ESMTP id k3LINaGY093672 for ; Fri, 21 Apr 2006 18:23:36 GMT (envelope-from imp@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.13.1/8.13.1/Submit) id k3LINajI093666 for perforce@freebsd.org; Fri, 21 Apr 2006 18:23:36 GMT (envelope-from imp@freebsd.org) Date: Fri, 21 Apr 2006 18:23:36 GMT Message-Id: <200604211823.k3LINajI093666@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to imp@freebsd.org using -f From: Warner Losh To: Perforce Change Reviews Cc: Subject: PERFORCE change 95808 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 21 Apr 2006 18:23:37 -0000 http://perforce.freebsd.org/chv.cgi?CH=95808 Change 95808 by imp@imp_hammer on 2006/04/21 18:22:46 fix minor bugs processing automatic characters. Affected files ... .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/env_vars.c#5 edit .. //depot/projects/arm/src/sys/boot/arm/at91/libat91/loader_prompt.c#10 edit Differences ... ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/env_vars.c#5 (text+ko) ==== @@ -60,6 +60,7 @@ if (ch == '\0' || (currentOffset >= MAX_INPUT_SIZE)) { currentOffset = 0; ++currentIndex; + ch = '\r'; } return (ch); } ==== //depot/projects/arm/src/sys/boot/arm/at91/libat91/loader_prompt.c#10 (text+ko) ==== @@ -360,23 +360,20 @@ * Each command is terminated with NULL (0) or '\r'. * .KB_C_FN_DEFINITION_END */ -static void ServicePrompt(char p_char) { - - if (p_char == '\r') { +static void +ServicePrompt(char p_char) +{ + if (p_char == '\r') p_char = 0; - } - if (p_char != 0x8) { if (buffCount < MAX_INPUT_SIZE-1) { - inputBuffer[buffCount] = p_char; ++buffCount; putchar(p_char); } } else if (buffCount) { - /* handle backspace BS */ --buffCount; inputBuffer[buffCount] = 0;