Deleted Added
full compact
print.c (241014) print.c (242725)
1/*-
2 * Copyright (c) 1989, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Michael Fischbein.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 22 unchanged lines hidden (view full) ---

31 */
32
33#if 0
34#ifndef lint
35static char sccsid[] = "@(#)print.c 8.4 (Berkeley) 4/17/94";
36#endif /* not lint */
37#endif
38#include <sys/cdefs.h>
1/*-
2 * Copyright (c) 1989, 1993, 1994
3 * The Regents of the University of California. All rights reserved.
4 *
5 * This code is derived from software contributed to Berkeley by
6 * Michael Fischbein.
7 *
8 * Redistribution and use in source and binary forms, with or without

--- 22 unchanged lines hidden (view full) ---

31 */
32
33#if 0
34#ifndef lint
35static char sccsid[] = "@(#)print.c 8.4 (Berkeley) 4/17/94";
36#endif /* not lint */
37#endif
38#include <sys/cdefs.h>
39__FBSDID("$FreeBSD: head/bin/ls/print.c 241014 2012-09-27 23:31:12Z mdf $");
39__FBSDID("$FreeBSD: head/bin/ls/print.c 242725 2012-11-08 00:24:26Z grog $");
40
41#include <sys/param.h>
42#include <sys/stat.h>
43#include <sys/acl.h>
44
45#include <err.h>
46#include <errno.h>
47#include <fts.h>

--- 553 unchanged lines hidden (view full) ---

601 * Reserve one space before the size and allocate room for
602 * the trailing '\0'.
603 */
604 char buf[HUMANVALSTR_LEN - 1 + 1];
605
606 humanize_number(buf, sizeof(buf), (int64_t)bytes, "",
607 HN_AUTOSCALE, HN_B | HN_NOSPACE | HN_DECIMAL);
608 (void)printf("%*s ", (u_int)width, buf);
40
41#include <sys/param.h>
42#include <sys/stat.h>
43#include <sys/acl.h>
44
45#include <err.h>
46#include <errno.h>
47#include <fts.h>

--- 553 unchanged lines hidden (view full) ---

601 * Reserve one space before the size and allocate room for
602 * the trailing '\0'.
603 */
604 char buf[HUMANVALSTR_LEN - 1 + 1];
605
606 humanize_number(buf, sizeof(buf), (int64_t)bytes, "",
607 HN_AUTOSCALE, HN_B | HN_NOSPACE | HN_DECIMAL);
608 (void)printf("%*s ", (u_int)width, buf);
609 } else
609 } else if (f_thousands) { /* with commas */
610 /* This format assignment needed to work round gcc bug. */
611 const char *format = "%*j'd ";
612 (void)printf(format, (u_int)width, bytes);
613 } else
610 (void)printf("%*jd ", (u_int)width, bytes);
611}
612
613/*
614 * Add a + after the standard rwxrwxrwx mode if the file has an
615 * ACL. strmode() reserves space at the end of the string.
616 */
617static void

--- 65 unchanged lines hidden ---
614 (void)printf("%*jd ", (u_int)width, bytes);
615}
616
617/*
618 * Add a + after the standard rwxrwxrwx mode if the file has an
619 * ACL. strmode() reserves space at the end of the string.
620 */
621static void

--- 65 unchanged lines hidden ---