mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-04 12:28:58 +00:00
Give correct results for SYSCTL_LONG arrays when sizeof(int) != sizeof(long)
This fixes unaligned access on alpha for, eg, sysctl kern.ipc.mbtypes.
This commit is contained in:
parent
fc11653f20
commit
3c884b5097
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=67476
@ -422,8 +422,8 @@ show_var(int *oid, int nlen)
|
|||||||
else
|
else
|
||||||
printf("%s%ld", val, *(long *)p);
|
printf("%s%ld", val, *(long *)p);
|
||||||
val = " ";
|
val = " ";
|
||||||
len -= sizeof (int);
|
len -= sizeof (long);
|
||||||
p += sizeof (int);
|
p += sizeof (long);
|
||||||
}
|
}
|
||||||
return (0);
|
return (0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user