Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/netbsd-3]: src/sys/arch/sparc/stand/common Pull up revision 1.16 (reques...



details:   https://anonhg.NetBSD.org/src/rev/cfadd8cf7137
branches:  netbsd-3
changeset: 575612:cfadd8cf7137
user:      tron <tron%NetBSD.org@localhost>
date:      Thu Apr 28 11:05:56 2005 +0000

description:
Pull up revision 1.16 (requested by martin in ticket #210):
Do not rely on strings to which pointers are returned by promlib functions
to persist accross further promlib calls.
This fixes (at least) bootjs.net.

diffstat:

 sys/arch/sparc/stand/common/promdev.c |  6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diffs (27 lines):

diff -r 8f635ac6e40c -r cfadd8cf7137 sys/arch/sparc/stand/common/promdev.c
--- a/sys/arch/sparc/stand/common/promdev.c     Thu Apr 28 11:05:50 2005 +0000
+++ b/sys/arch/sparc/stand/common/promdev.c     Thu Apr 28 11:05:56 2005 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: promdev.c,v 1.15 2003/07/30 15:58:40 mrg Exp $ */
+/*     $NetBSD: promdev.c,v 1.15.14.1 2005/04/28 11:05:56 tron Exp $ */
 
 /*
  * Copyright (c) 1993 Paul Kranenburg
@@ -91,7 +91,7 @@
        { "obp v2", obp_v2_strategy, null_devopen, obp_close, null_devioctl };
 
 
-char   *prom_bootdevice;
+char   prom_bootdevice[MAX_PROM_PATH];
 static int     saveecho;
 
 
@@ -139,7 +139,7 @@
        case PROM_OBP_V2:
        case PROM_OBP_V3:
        case PROM_OPENFIRM:
-               if (prom_bootdevice == NULL) {
+               if (*prom_bootdevice == '\0') {
                        error = ENXIO;
                        break;
                }



Home | Main Index | Thread Index | Old Index