FreeBSD Bugzilla – Attachment 10561 Details for
Bug 21132
setting kern.hostid to 2887705710 fails.
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
file.diff
file.diff (text/plain), 2.97 KB, created by
Jim.Pirzyk
on 2000-09-08 21:40:01 UTC
(
hide
)
Description:
file.diff
Filename:
MIME Type:
Creator:
Jim.Pirzyk
Created:
2000-09-08 21:40:01 UTC
Size:
2.97 KB
patch
obsolete
>*** sbin/sysctl/sysctl.c.orig Fri Sep 8 12:55:12 2000 >--- sbin/sysctl/sysctl.c Fri Sep 8 13:03:46 2000 >*************** >*** 121,127 **** > { > int len, i, j; > void *newval = 0; >! int intval, newsize = 0; > quad_t quadval; > int mib[CTL_MAXNAME]; > char *cp, *bufp, buf[BUFSIZ]; >--- 122,128 ---- > { > int len, i, j; > void *newval = 0; >! unsigned int intval, newsize = 0; > quad_t quadval; > int mib[CTL_MAXNAME]; > char *cp, *bufp, buf[BUFSIZ]; >*************** >*** 167,173 **** > > switch (kind & CTLTYPE) { > case CTLTYPE_INT: >! intval = (int) strtol(newval, NULL, 0); > newval = &intval; > newsize = sizeof intval; > break; >--- 168,174 ---- > > switch (kind & CTLTYPE) { > case CTLTYPE_INT: >! intval = (unsigned int) strtoul(newval, NULL, 0); > newval = &intval; > newsize = sizeof intval; > break; >*** sys/kern/kern_mib.c.orig Fri Sep 8 12:17:20 2000 >--- sys/kern/kern_mib.c Fri Sep 8 12:29:55 2000 >*************** >*** 186,194 **** > SYSCTL_STRING(_kern, KERN_NISDOMAINNAME, domainname, CTLFLAG_RW, > &domainname, sizeof(domainname), "Name of the current YP/NIS domain"); > >! long hostid; > /* Some trouble here, if sizeof (int) != sizeof (long) */ >! SYSCTL_INT(_kern, KERN_HOSTID, hostid, CTLFLAG_RW, &hostid, 0, "Host ID"); > > /* > * This is really cheating. These actually live in the libc, something >--- 186,194 ---- > SYSCTL_STRING(_kern, KERN_NISDOMAINNAME, domainname, CTLFLAG_RW, > &domainname, sizeof(domainname), "Name of the current YP/NIS domain"); > >! unsigned long hostid; > /* Some trouble here, if sizeof (int) != sizeof (long) */ >! SYSCTL_UINT(_kern, KERN_HOSTID, hostid, CTLFLAG_RW, &hostid, 0, "Host ID"); > > /* > * This is really cheating. These actually live in the libc, something >*** sys/kern/kern_xxx.c.orig Fri Sep 8 12:35:33 2000 >--- sys/kern/kern_xxx.c Fri Sep 8 12:36:17 2000 >*************** >*** 103,109 **** > struct ogethostid_args *uap; > { > >! *(long *)(p->p_retval) = hostid; > return (0); > } > #endif /* COMPAT_43 || COMPAT_SUNOS */ >--- 103,109 ---- > struct ogethostid_args *uap; > { > >! *(unsigned long *)(p->p_retval) = hostid; > return (0); > } > #endif /* COMPAT_43 || COMPAT_SUNOS */ >*************** >*** 111,117 **** > #ifdef COMPAT_43 > #ifndef _SYS_SYSPROTO_H_ > struct osethostid_args { >! long hostid; > }; > #endif > /* ARGSUSED */ >--- 111,117 ---- > #ifdef COMPAT_43 > #ifndef _SYS_SYSPROTO_H_ > struct osethostid_args { >! unsigned long hostid; > }; > #endif > /* ARGSUSED */ >*** sys/sys/kernel.h.orig Fri Sep 8 12:18:01 2000 >--- sys/sys/kernel.h Fri Sep 8 12:18:12 2000 >*************** >*** 55,61 **** > /* Global variables for the kernel. */ > > /* 1.1 */ >! extern long hostid; > extern char hostname[MAXHOSTNAMELEN]; > extern int hostnamelen; > extern char domainname[MAXHOSTNAMELEN]; >--- 55,61 ---- > /* Global variables for the kernel. */ > > /* 1.1 */ >! extern unsigned long hostid; > extern char hostname[MAXHOSTNAMELEN]; > extern int hostnamelen; > extern char domainname[MAXHOSTNAMELEN];
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 21132
: 10561