summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2006-07-29(set_author): Preserve the st_author field via thePaul Eggert
file descriptor dest_desc.
2006-07-27* src/chgrp.c (usage): Use correct grammar in description of the --reference ↵Jim Meyering
option * src/chown.c (usage): Likewise.
2006-07-26* src/copy.c (set_author) [HAVE_STRUCT_STAT_ST_AUTHOR]:Jim Meyering
Correctly access SRC_SB's element ST_AUTHOR.
2006-07-26* src/ls.c (print_color_indicator): Test for S_IFREG first, ratherJim Meyering
than having the code test for all of the other types first. Hoist the set-uid/gid-testing code "up" into this new block. Classify any other type of file (e.g., S_TYPEISSHM, etc.) as C_ORPHAN, not as C_FILE. * doc/coreutils.texi (What information is listed): Mention that missing pieces of information are marked with "?". From Paul Eggert.
2006-07-26Checking in a change from Paul.Jim Meyering
2006-07-25 Paul Eggert <eggert@cs.ucla.edu> * src/ls.c (DT_INIT): Remove. All uses removed. (enum filetype): Use an ordinary enum rather than trying to keep the values in sync with DT_FIFO etc. That way, we don't have to make special assumptions about them. All uses changed. (whiteout): New constant member of enum filetype. (filetype_letter): New constant, for use with enum filetype. (FILETYPE_INDICATORS): New initializer list. (print_dir): Add case for DT_WHT. (gobble_file): If stat fails, don't discard information from readdir; instead, preserve it so it can be printed. (print_long_format): Fall back on readdir result if stat info is not available. Use "?" to denote each unknown mode char, instead of an overall "?", since we now know some of the mode typically. (print_type_indicator): Now that MODE isn't necessarily useful, guard all uses. Now that two blocks in the type-checking tree can set "type = C_FILE", move the suffix-handling code out and down.
2006-07-26Prepare for the above change.Jim Meyering
* src/ls.c [struct fileinfo] (stat_ok): Rename from stat_failed, and adjust uses. From a patch by Paul Eggert.
2006-07-26* src/ls.c: Correct indentation/formatting in a few places.Jim Meyering
2006-07-25* src/ls.c (gobble_file): When handling a stat-failed entry,Jim Meyering
print the entry name not the absolute_name -- to be consistent with the usual case. * tests/ls/stat-failed: Update accordingly.
2006-07-25* src/dircolors.hin: Mention that ORPHAN refers not just to dangling symlinks.Jim Meyering
2006-07-25* src/dircolors.hin: Mention that ORPHAN refers not just to dangling symlinks.Jim Meyering
2006-07-25Get --dired offsets right when handling stat-failed entries.Jim Meyering
* src/ls.c (print_long_format): Be careful to increment P by the appropriate amount, even when inode_number_width and nlink_width are zero. * tests/ls/stat-failed: Test for the above.
2006-07-25* src/ls.c (gobble_file) [USE_ACL]: Don't use-uninitialized theJim Meyering
have_acl member. That would happen for a directory with both a non-stat'able entry and one with an ACL.
2006-07-25* src/ls.c (gobble_file): Make it so failure to stat aJim Meyering
non-command-line file provokes an exit status of 1, not 0. Say "cannot access" rather than "cannot stat". * tests/ls/stat-failed: New file/test, for the above. * tests/ls/Makefile.am (TESTS): Add stat-failed.
2006-07-25* src/ls.c: Declare stat_failed to be "bool", not "int" everywhere.Jim Meyering
2006-07-25* src/ls.c [enum filetype] (command_line): Remove member. Not needed.Jim Meyering
Replace all occurrences of "type == command_line" with the equivalent, "command_line_arg".
2006-07-25* src/ls.c: Apply the stat-failed parts of Red Hat'sJim Meyering
coreutils-selinux.patch. From Ulrich Drepper. This makes it so files not mentioned on the command line (e.g., names read from a directory that *is* mentioned on the command line) for which stat fails are still listed. With --color, such files are colored just like ORPHANs (aka dangling symlinks).
2006-07-25* src/df.c (n_valid_args): Declare global to be static.Jim Meyering
2006-07-21* src/su.c (usage): Correct typo in --help output: s/commmand/command/Jim Meyering
Reported by Tim Waugh. Also remove the comment duplicating much of --help output.
2006-07-21(FILE_TYPE_INDICATOR_OPTION): Reposition this new name so the list remains ↵Jim Meyering
alphabetized.
2006-07-21Fix another bug: ls --indicator-style=file-type would callJim Meyering
stat for a symlink, even though it wasn't always needed. In some cases, that unnecessary stat would cause ls to fail. * src/ls.c (gobble_file): Don't treat symlinks specially (in requiring a stat syscall). Remove the offending exclusion. * NEWS: Mention the fix. * tests/ls/stat-dtype: New file/test, for the above fix. Also exercises the new df feature, below.
2006-07-20* src/df.c (main): Fail and don't print the headers if noJim Meyering
file system is processed. This makes it easy to test whether a specified directory is on a file system of a given type or types. Otherwise, applications would have had to parse df's output. E.g., is "." either ext3 or reiserfs: df -t ext3 -t reiserfs .
2006-07-20Fix a bug: ls --file-type worked like --indicator-style=slash,Jim Meyering
rather than like --indicator-style=file-type. (FILE_TYPE_INDICATOR_OPTION): New enum member. (long_options): Map "file-type" to FILE_TYPE_INDICATOR_OPTION, not to 'p'. (decode_switches): Handle new case: FILE_TYPE_INDICATOR_OPTION.
2006-07-19* src/ls.c (print_dir): Give a better diagnostic for failed opendir.Jim Meyering
2006-07-17Regenerate.Paul Eggert
2006-07-17(main): Adjust to new mode_adjust API.Paul Eggert
2006-07-17(main): Adjust to new mode_adjust API.Paul Eggert
2006-07-17(struct mkdir_options): New struct.Paul Eggert
(announce_mkdir, make_ancestor): New functions. (main): Use them. Adjust to mode_adjust API change. Stick with umask 0. Use make_dir_parents for all the work.
2006-07-17Include mkancesdirs.h.Paul Eggert
(announce_mkdir, make_ancestor): New functions. (DEFAULT_MODE): New macro, specifying initial value of 'mode'. (mode): Use it. (dir_mode, dir_mode_bits): New vars. (main): Set dir modes separately from nondir, so that the X op of -m works correctly. (main): Remove cwd_errno cruft, since make_dir_parents no longer affects cwd. Adjust to new make_dir_parents API. (install_file_in_file_parents): 2nd arg is now char *, not char const *. Use mkancesdirs instead of rolling our own code. (change_attributes): Don't worry about AFS, since that kludge should not be needed any more.
2006-07-17(process_file): Adjust to mode_adjust API change.Paul Eggert
2006-07-14(do_decode): Output to parameter OUT, not to stdout.Paul Eggert
2006-07-11Assume <dirent.h> exists, since gnulib assumes this now as well.Paul Eggert
2006-07-09Regenerate.Paul Eggert
2006-07-09Adjust to today's renaming changes in system.h.Paul Eggert
2006-07-09(print_it): Don't assume char is unsigned.Paul Eggert
2006-07-09(print_esc): Don't assume char is unsigned.Paul Eggert
2006-07-09(create_fullname): Don't assume char is unsigned.Paul Eggert
2006-07-09(is_blank): Remove; no longer needed. All usesPaul Eggert
replaced by isblank (to_uchar (...)).
2006-07-09(unexpand): Don't assume that isprint etc. returnPaul Eggert
booleans (needed for pre-C99 hosts).
2006-07-09(is_char_class_member): Don't assume that isprint etc. returnPaul Eggert
booleans (needed for pre-C99 hosts).
2006-07-09(initialize_regex, fix_output_parameters): Don't assume that isprintPaul Eggert
etc. return booleans (needed for pre-C99 hosts). (SKIP_NON_WHITE, SKIP_WHITE, SKIP_WHITE_BACKWARDS): (copy_unescaped_string): Don't assume char is unsigned.
2006-07-09(check_punctuation): Don't assume that isprint etc. returnPaul Eggert
booleans (needed for pre-C99 hosts).
2006-07-09(expand): Don't assume that isprint etc. returnPaul Eggert
booleans (needed for pre-C99 hosts).
2006-07-09(inittables): Use toupper rather thanPaul Eggert
islower followed by toupper; it's simpler and typically faster now that we assume at least C89 semantics. Similarly for tolower.
2006-07-09(apply_translations): Use toupper rather thanPaul Eggert
islower followed by toupper; it's simpler and typically faster now that we assume at least C89 semantics. Similarly for tolower.
2006-07-09(_D_EXACT_NAMELEN): Renamed from NLENGTH, forPaul Eggert
convenience on GNU systems. All uses changed. Don't bother looking for any dirent.h substitute other than ndir.h. (D_INO): Remove unnecessary parentheses. (IN_CTYPE_DOMAIN, ISGRAPH, ISPRINT, ISALNUM, ISALPHA): (ISCNTRL, ISLOWER, ISPUNCT, ISSPACE, ISUPPER, ISXDIGIT): (ISDIGIT_LOCALE, TOLOWER, TOUPPER): Remove. All uses changed to ctype.h equivalents. (isblank): Renamed from ISBLANK. Check for HAVE_DECL_ISBLANK too. All uses changed.
2006-07-08* src/dd.c (skip): Remove one of two adjacent "the"s in a comment.Jim Meyering
2006-07-05* src/ls.c (usage): Correct the description of -G: it is usefulJim Meyering
only in a long listing. Reported by Martin Pool in <https://launchpad.net/distros/ubuntu/+source/coreutils/+bug/51653>.
2006-07-05* src/copy.c (copy_internal): Don't work around old NFS clients likeJim Meyering
SunOS-4.1.4 and Irix 5.3 that set errno to values like EIO and ENOTEMPTY upon failed rename. Otherwise, we risk misinterpreting a banal failure as a recursive move-into-self failure. Reported by Florent Bayle in <http://bugs.debian.org/376749>.
2006-07-05Regenerate, to remove fuzz.Jim Meyering
2006-07-03Plug another unusual leak.Jim Meyering
(AD_mark_helper): Free malloc'd filename if hash_insert says that string is already in the hash table.