Module Name: src
Committed By: christos
Date: Sun Dec 13 18:24:50 UTC 2015
Modified Files:
src/sys/arch/emips/stand/common: boot.c
Log Message:
PR/50537: David Binderman: fix bad sizeof
To generate a diff of this commit:
cvs rdiff -u -r1.3 -r1.4 src/sys/arch/emips/stand/common/boot.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/emips/stand/common/boot.c
diff -u src/sys/arch/emips/stand/common/boot.c:1.3 src/sys/arch/emips/stand/common/boot.c:1.4
--- src/sys/arch/emips/stand/common/boot.c:1.3 Wed Mar 26 12:10:20 2014
+++ src/sys/arch/emips/stand/common/boot.c Sun Dec 13 13:24:50 2015
@@ -1,4 +1,4 @@
-/* $NetBSD: boot.c,v 1.3 2014/03/26 16:10:20 christos Exp $ */
+/* $NetBSD: boot.c,v 1.4 2015/12/13 18:24:50 christos Exp $ */
/*-
* Copyright (c) 2010 The NetBSD Foundation, Inc.
@@ -64,10 +64,10 @@ static int devcanon(char *);
#define OPT_MAX PATH_MAX /* way overkill */
-static int loadit(char *name, u_long marks[MARK_MAX])
+static int loadit(char *name, u_long *marks)
{
printf("Loading: %s\n", name);
- memset(marks, 0, sizeof marks);
+ memset(marks, 0, sizeof(*marks) * MARK_MAX);
return (loadfile(name, marks, LOAD_ALL));
}