diff --git a/sbin/sysctl/sysctl.c b/sbin/sysctl/sysctl.c index bb5c4c17b62d..b712a2660453 100644 --- a/sbin/sysctl/sysctl.c +++ b/sbin/sysctl/sysctl.c @@ -533,7 +533,7 @@ show_var(int *oid, int nlen) case 'A': if (!nflag) printf("%s%s", name, sep); - printf("%s", p); + printf("%.*s", len, p); return (0); case 'I':