aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2010-04-13 21:55:18 +0200
committerNguyễn Thái Ngọc Duy <pclouds@gmail.com>2010-09-10 19:49:30 +1000
commit970b17acd321b27dfb81d0a9447cc8404d6d602e (patch)
tree582b4f862571da566fb9ea03f0450a3a46859a3f
parent1d9c0f9e35ff48d51885025679c920d2f78ab242 (diff)
downloadbusybox-w32-970b17acd321b27dfb81d0a9447cc8404d6d602e.tar.gz
busybox-w32-970b17acd321b27dfb81d0a9447cc8404d6d602e.tar.bz2
busybox-w32-970b17acd321b27dfb81d0a9447cc8404d6d602e.zip
win32: ls: ignore stat.st_blocks on Windows
-rw-r--r--coreutils/ls.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c
index 1197f7d71..c7b2161db 100644
--- a/coreutils/ls.c
+++ b/coreutils/ls.c
@@ -612,7 +612,12 @@ static NOINLINE unsigned list_single(const struct dnode *dn)
612 if (all_fmt & LIST_INO) 612 if (all_fmt & LIST_INO)
613 column += printf("%7llu ", (long long) dn->dstat.st_ino); 613 column += printf("%7llu ", (long long) dn->dstat.st_ino);
614 if (all_fmt & LIST_BLOCKS) 614 if (all_fmt & LIST_BLOCKS)
615#if ENABLE_PLATFORM_MINGW32
616 /* MinGW does not have st_blocks */
617 column += printf("%4"OFF_FMT"u ", (off_t)0);
618#else
615 column += printf("%4"OFF_FMT"u ", (off_t) (dn->dstat.st_blocks >> 1)); 619 column += printf("%4"OFF_FMT"u ", (off_t) (dn->dstat.st_blocks >> 1));
620#endif
616 if (all_fmt & LIST_MODEBITS) 621 if (all_fmt & LIST_MODEBITS)
617 column += printf("%-10s ", (char *) bb_mode_string(dn->dstat.st_mode)); 622 column += printf("%-10s ", (char *) bb_mode_string(dn->dstat.st_mode));
618 if (all_fmt & LIST_NLINKS) 623 if (all_fmt & LIST_NLINKS)