Module Name:    src
Committed By:   dholland
Date:           Sat Jun 11 06:58:42 UTC 2016

Modified Files:
        src/sys/arch/zaurus/stand/zboot: boot.c bootmenu.c

Log Message:
PR 51200 gets in libsa considered harmful: use kgets


To generate a diff of this commit:
cvs rdiff -u -r1.7 -r1.8 src/sys/arch/zaurus/stand/zboot/boot.c
cvs rdiff -u -r1.4 -r1.5 src/sys/arch/zaurus/stand/zboot/bootmenu.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/arch/zaurus/stand/zboot/boot.c
diff -u src/sys/arch/zaurus/stand/zboot/boot.c:1.7 src/sys/arch/zaurus/stand/zboot/boot.c:1.8
--- src/sys/arch/zaurus/stand/zboot/boot.c:1.7	Tue May 31 04:13:26 2016
+++ src/sys/arch/zaurus/stand/zboot/boot.c	Sat Jun 11 06:58:42 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: boot.c,v 1.7 2016/05/31 04:13:26 dholland Exp $	*/
+/*	$NetBSD: boot.c,v 1.8 2016/06/11 06:58:42 dholland Exp $	*/
 
 /*
  * Copyright (c) 2009 NONAKA Kimihiro <[email protected]>
@@ -416,7 +416,7 @@ bootmenu(void)
 
 		input[0] = '\0';
 		printf("> ");
-		gets(input);
+		kgets(input, sizeof(input));
 
 		/*
 		 * Skip leading whitespace.

Index: src/sys/arch/zaurus/stand/zboot/bootmenu.c
diff -u src/sys/arch/zaurus/stand/zboot/bootmenu.c:1.4 src/sys/arch/zaurus/stand/zboot/bootmenu.c:1.5
--- src/sys/arch/zaurus/stand/zboot/bootmenu.c:1.4	Sun Aug 10 07:40:50 2014
+++ src/sys/arch/zaurus/stand/zboot/bootmenu.c	Sat Jun 11 06:58:42 2016
@@ -1,4 +1,4 @@
-/*	$NetBSD: bootmenu.c,v 1.4 2014/08/10 07:40:50 isaki Exp $	*/
+/*	$NetBSD: bootmenu.c,v 1.5 2016/06/11 06:58:42 dholland Exp $	*/
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -99,7 +99,7 @@ doboottypemenu(void)
 				printf("\nOption: [%d]:",
 				    bootcfg_info.def + 1);
 
-			gets(input);
+			kgets(input, sizeof(input));
 			choice = getchoicefrominput(input, bootcfg_info.def);
 		} else if (bootcfg_info.timeout == 0)
 			choice = bootcfg_info.def;

Reply via email to