summaryrefslogtreecommitdiff
path: root/coreutils/ls.c
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2006-04-12 07:35:12 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2006-04-12 07:35:12 +0000
commitcb44816ba32a3bbf598aab6d7cb1eabfd6619f5f (patch)
tree4459d66dd948b019c4a96730eea224f79520ad8c /coreutils/ls.c
parentd0ea52ee041ca4d8d00cc5212d54328689b1a3c4 (diff)
downloadbusybox-w32-cb44816ba32a3bbf598aab6d7cb1eabfd6619f5f.tar.gz
busybox-w32-cb44816ba32a3bbf598aab6d7cb1eabfd6619f5f.tar.bz2
busybox-w32-cb44816ba32a3bbf598aab6d7cb1eabfd6619f5f.zip
- add and use bb_opendir(), bb_xopendir().
text data bss dec hex filename 889445 9392 1035784 1934621 1d851d busybox.gcc-4.2.orig 889297 9392 1035784 1934473 1d8489 busybox.gcc-4.2 889009 9820 1037860 1936689 1d8d31 busybox.gcc-4.1.orig 888817 9820 1037860 1936497 1d8c71 busybox.gcc-4.1
Diffstat (limited to 'coreutils/ls.c')
-rw-r--r--coreutils/ls.c17
1 files changed, 2 insertions, 15 deletions
diff --git a/coreutils/ls.c b/coreutils/ls.c
index 964e7c964..c9d24ff4a 100644
--- a/coreutils/ls.c
+++ b/coreutils/ls.c
@@ -3,19 +3,7 @@
3 * tiny-ls.c version 0.1.0: A minimalist 'ls' 3 * tiny-ls.c version 0.1.0: A minimalist 'ls'
4 * Copyright (C) 1996 Brian Candler <B.Candler@pobox.com> 4 * Copyright (C) 1996 Brian Candler <B.Candler@pobox.com>
5 * 5 *
6 * This program is free software; you can redistribute it and/or modify 6 * Licensed under GPLv2 or later, see file LICENSE in this tarball for details.
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
10 *
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
15 *
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
19 */ 7 */
20 8
21/* 9/*
@@ -592,9 +580,8 @@ static struct dnode **list_dir(const char *path)
592 580
593 dn = NULL; 581 dn = NULL;
594 nfiles = 0; 582 nfiles = 0;
595 dir = opendir(path); 583 dir = bb_opendir(path);
596 if (dir == NULL) { 584 if (dir == NULL) {
597 bb_perror_msg("%s", path);
598 status = EXIT_FAILURE; 585 status = EXIT_FAILURE;
599 return (NULL); /* could not open the dir */ 586 return (NULL); /* could not open the dir */
600 } 587 }