Module Name: src Committed By: rin Date: Tue Mar 23 07:21:16 UTC 2021
Modified Files: src/sys/arch/sandpoint/stand/altboot: main.c Log Message: Make sure not to run kernel if fdloadfile() fails; it returns *non-zero* value on error. To generate a diff of this commit: cvs rdiff -u -r1.31 -r1.32 src/sys/arch/sandpoint/stand/altboot/main.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/sandpoint/stand/altboot/main.c diff -u src/sys/arch/sandpoint/stand/altboot/main.c:1.31 src/sys/arch/sandpoint/stand/altboot/main.c:1.32 --- src/sys/arch/sandpoint/stand/altboot/main.c:1.31 Wed Jun 26 22:04:12 2019 +++ src/sys/arch/sandpoint/stand/altboot/main.c Tue Mar 23 07:21:15 2021 @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.31 2019/06/26 22:04:12 christos Exp $ */ +/* $NetBSD: main.c,v 1.32 2021/03/23 07:21:15 rin Exp $ */ /*- * Copyright (c) 2007 The NetBSD Foundation, Inc. @@ -345,7 +345,7 @@ main(int argc, char *argv[], char *boota err = fdloadfile(fd, marks, LOAD_KERNEL); close(fd); - if (err < 0) + if (err != 0) continue; printf("entry=%p, ssym=%p, esym=%p\n",