Source-Changes-HG archive

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

[src/netbsd-2-0]: src/sys/compat/svr4 Pullup rev 1.51 (requested by dmcmahill...



details:   https://anonhg.NetBSD.org/src/rev/cf75f571de70
branches:  netbsd-2-0
changeset: 560464:cf75f571de70
user:      jmc <jmc%NetBSD.org@localhost>
date:      Wed Apr 21 03:12:23 2004 +0000

description:
Pullup rev 1.51 (requested by dmcmahill in ticket #161)

Fix the sysinfo(SI_HW_SERIAL, emulation so that we actually get the
hostid of the machine rather than always getting "0"

diffstat:

 sys/compat/svr4/svr4_stat.c |  7 ++++---
 1 files changed, 4 insertions(+), 3 deletions(-)

diffs (28 lines):

diff -r 06edcb54fb35 -r cf75f571de70 sys/compat/svr4/svr4_stat.c
--- a/sys/compat/svr4/svr4_stat.c       Wed Apr 21 03:12:17 2004 +0000
+++ b/sys/compat/svr4/svr4_stat.c       Wed Apr 21 03:12:23 2004 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: svr4_stat.c,v 1.50 2003/12/04 19:38:23 atatat Exp $     */
+/*     $NetBSD: svr4_stat.c,v 1.50.2.1 2004/04/21 03:12:23 jmc Exp $    */
 
 /*-
  * Copyright (c) 1994 The NetBSD Foundation, Inc.
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: svr4_stat.c,v 1.50 2003/12/04 19:38:23 atatat Exp $");
+__KERNEL_RCSID(0, "$NetBSD: svr4_stat.c,v 1.50.2.1 2004/04/21 03:12:23 jmc Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -620,7 +620,8 @@
                break;
 
        case SVR4_SI_HW_SERIAL:
-               str = "0";
+               snprintf(buf, sizeof(buf), "%lu", hostid);
+               str = buf;
                break;
 
        case SVR4_SI_HW_PROVIDER:



Home | Main Index | Thread Index | Old Index