summaryrefslogtreecommitdiffstats
path: root/bin/ls/print.c
diff options
context:
space:
mode:
authorsteve <steve@FreeBSD.org>1996-12-14 06:03:29 +0000
committersteve <steve@FreeBSD.org>1996-12-14 06:03:29 +0000
commit69ca26a30523449bee72a8ea347bfcc2b42d077c (patch)
tree163f19c661895d601b0a50b8c43ae2b7724325db /bin/ls/print.c
parentbf89557b965b65cdaf9e19c5c46ee200420c354e (diff)
downloadFreeBSD-src-69ca26a30523449bee72a8ea347bfcc2b42d077c.zip
FreeBSD-src-69ca26a30523449bee72a8ea347bfcc2b42d077c.tar.gz
Merge Lite2 mods, and -Wall cleaning. undelete(2) cruft
not yet implemented is protected by a define (BSD4_4_LITE) that should be removed when this call is supported by the kernel.
Diffstat (limited to 'bin/ls/print.c')
-rw-r--r--bin/ls/print.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/bin/ls/print.c b/bin/ls/print.c
index 5f96695..e7b63f0 100644
--- a/bin/ls/print.c
+++ b/bin/ls/print.c
@@ -33,11 +33,11 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: print.c,v 1.7 1995/12/30 18:15:30 joerg Exp $
+ * $Id: print.c,v 1.8 1996/01/20 10:31:14 mpp Exp $
*/
#ifndef lint
-static char sccsid[] = "@(#)print.c 8.4 (Berkeley) 4/17/94";
+static char const sccsid[] = "@(#)print.c 8.4 (Berkeley) 4/17/94";
#endif /* not lint */
#include <sys/param.h>
@@ -95,7 +95,7 @@ printlong(dp)
continue;
sp = p->fts_statp;
if (f_inode)
- (void)printf("%*lu ", dp->s_inode, sp->st_ino);
+ (void)printf("%*lu ", dp->s_inode, (u_long)sp->st_ino);
if (f_size)
(void)printf("%*qd ",
dp->s_block, howmany(sp->st_blocks, blocksize));
@@ -215,7 +215,7 @@ printaname(p, inodefield, sizefield)
sp = p->fts_statp;
chcnt = 0;
if (f_inode)
- chcnt += printf("%*lu ", (int)inodefield, sp->st_ino);
+ chcnt += printf("%*lu ", (int)inodefield, (u_long)sp->st_ino);
if (f_size)
chcnt += printf("%*qd ",
(int)sizefield, howmany(sp->st_blocks, blocksize));
@@ -268,6 +268,11 @@ printtype(mode)
case S_IFSOCK:
(void)putchar('=');
return (1);
+#ifndef BSD4_4_LITE
+ case S_IFWHT:
+ (void)putchar('%');
+ return (1);
+#endif
}
if (mode & (S_IXUSR | S_IXGRP | S_IXOTH)) {
(void)putchar('*');
OpenPOWER on IntegriCloud