svn commit: r334514 - head/usr.bin/top

Allan Jude allanjude at freebsd.org
Thu Jun 14 00:10:30 UTC 2018


On 2018-06-01 23:25, Eitan Adler wrote:
> Author: eadler
> Date: Sat Jun  2 03:25:15 2018
> New Revision: 334514
> URL: https://svnweb.freebsd.org/changeset/base/334514
> 
> Log:
>   top(1): Use standard boolean rather than homegrown alternative
> 
> Deleted:
>   head/usr.bin/top/boolean.h
> Modified:
>   head/usr.bin/top/commands.c
>   head/usr.bin/top/display.c
>   head/usr.bin/top/machine.c
>   head/usr.bin/top/screen.c
>   head/usr.bin/top/top.1
>   head/usr.bin/top/top.c
> 
> Modified: head/usr.bin/top/machine.c
> ==============================================================================
> --- head/usr.bin/top/machine.c	Sat Jun  2 02:06:48 2018	(r334513)
> +++ head/usr.bin/top/machine.c	Sat Jun  2 03:25:15 2018	(r334514)
> @@ -35,6 +35,7 @@
>  #include <paths.h>
>  #include <pwd.h>
>  #include <stdio.h>
> +#include <stdbool.h>
>  #include <stdlib.h>
>  #include <string.h>
>  #include <strings.h>
> @@ -308,7 +309,7 @@ machine_init(struct statics *statics)
>  {
>  	int i, j, empty, pagesize;
>  	uint64_t arc_size;
> -	boolean_t carc_en;
> +	bool carc_en;
>  	size_t size;
>  
>  	size = sizeof(smpmode);
> 

This broke compressed ARC display in top. The sysctl
vfs.zfs.compressed_arc_enabled is backed by a boolean_t (which is the
same size as an int), so trying to read it into a bool (1 byte) fails
and returns ENOMEM.

Fixed in r335099

-- 
Allan Jude

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 834 bytes
Desc: OpenPGP digital signature
URL: <http://lists.freebsd.org/pipermail/svn-src-all/attachments/20180613/0ef72667/attachment.sig>


More information about the svn-src-all mailing list