summaryrefslogtreecommitdiff
path: root/src
AgeCommit message (Collapse)Author
2001-01-03Use the more precise algorithm of GNU "make" to decide whetherJim Meyering
a file is in the future, by looking at high-resolution time stamps if available. (TIMESPEC_NS): New macro. (current_time): Initialize to the minimum value. (current_time_ns): New var. (main): Do not bother to initialize current_time; it's no longer needed. (get_current_time): New function. (print_long_format): Use it when a file appears to be in the future. Get the nanoseconds of the file's time stamp, if available, and use that to decide whether the file appears to be in the future.
2001-01-03(main): Remove embedded \n from diagnostic.Jim Meyering
2001-01-03(long_time_expected_width, print_long_format): FixJim Meyering
bug: the initial byte passed to strftime wasn't initialized to a nonzero value after the buffer was reallocated.
2001-01-03(dcgettext): New macro.Jim Meyering
2001-01-03(decode_switches): Use dcgettext with LC_TIME,Jim Meyering
not plain gettext, to get the translations of time formats.
2001-01-03(long_time_expected_width): New function.Jim Meyering
(print_long_format): Use it, so that we don't assume a particular width for time stamps in an internationalized environment.
2001-01-02(ulonglong_t): Define place-holder type to avoid some #if directives.Jim Meyering
(LONGEST_INTEGRAL_TYPE): Remove definition. (MAX_INTEGRAL_TYPE_SIZE): Use ulonglong_t instead of LONGEST_INTEGRAL_TYPE. (print_long_long): Compile this function even on systems without long long support. (decode_one_format): Remove #if directive.
2001-01-02(decode_one_format): Guard use of print_long_long withJim Meyering
`#if HAVE_UNSIGNED_LONG_LONG'. From Darren Salt. Change all `#ifdef HAVE_UNSIGNED_LONG_LONG' to use `#if' instead.
2001-01-02copyrightJim Meyering
2001-01-02(print_long_format):Jim Meyering
Report the year for files even slightly in the future. Avoid overflow problems near Y2038 on 32-bit hosts. To calculate "six months", take half the average Gregorian year, not 180 days.
2000-12-31Improve performance by invoking gettext twice at the start,Jim Meyering
instead of once for each file. (long_time_format): New var. (decode_switches): Initialize it, if format == long_format. (print_long_format): Use it.
2000-12-31(print_long_format): Don't dump core if strftime returns the empty string.Jim Meyering
2000-12-31(gobble_file): If not using long format, don't invoke acl; it's not needed.Jim Meyering
2000-12-31Avoid an unnecessary `stat' when using --dereference.Jim Meyering
(same_file_ok): Use stat only if lstat reported that the file was a symbolic link.
2000-12-28tweak commentJim Meyering
2000-12-28tweak commentJim Meyering
2000-12-28(same_file_ok): Fix *another* typo from my 2000-09-03 change: ↵Jim Meyering
s/tmp_dst_sb/tmp_src_sb/.
2000-12-28(same_file_ok): Fix typo from my 2000-09-03 change: s/tmp_dst_sb/tmp_src_sb/.Jim Meyering
2000-12-28(same_file_ok): Use a single auto var forJim Meyering
tmp_dst_sb, instead of two static vars. Likewise for tmp_src_sb.
2000-12-25(same_file_ok): Remove declaration and set of unusedJim Meyering
variables: src_sb_no_link, dst_sb_no_link.
2000-12-25For both ln and install, when using `--backup=simple --suffix=S',Jim Meyering
the suffix `S' wasn't used. (main): Actually use the local variable, `backup_suffix_string'.
2000-12-25(hash_compare_active_dir_ents): Return explicit `true'Jim Meyering
or `false', rather than relying on implicit int-to-enum cast.
2000-12-25(extract_dirs_from_files): Remove unused variable.Jim Meyering
(gobble_file): Move decl of local, val, into the scope where it's used.
2000-12-24(main): Actually use the local variable, `backup_suffix_string'.Jim Meyering
2000-12-23[HAVE_INTTYPES_H]: Include <inttypes.h>.Jim Meyering
2000-12-22(isaac_seed_machdep) [_ARCH_PPC]: Disable the codeJim Meyering
that would use the PPC mfspr `asm' code.
2000-12-19(UINTMAX_MAX): New macro, taken from C99.Jim Meyering
2000-12-19adjust indentationJim Meyering
2000-12-19Include physmem.h.Jim Meyering
(SORTALLOC, mergealloc, LINEALLOC): Remove. (sortalloc): Default to zero at program startup. (SORTALLOC_MIN, SORTALLOC_DEFAULT_MIN): New macros. (usage, main): Add support for new -S SIZE option. (specify_sort_size, default_sort_size): New functions. (initlines): Do not let alloc exceed limit. (findlines): Likewise. (checkfp, mergefps, sort): Use sortalloc to size everything else, instead of relying on precomputed sizes.
2000-12-16(uint_to_string): New function.Jim Meyering
(uid_to_name): Use it. (gid_to_name): Use it. Rename locals, user/group, to uid/gid.
2000-12-16(enum Change_status): Start with 1.Jim Meyering
2000-12-16(main): Rename local, group, to gid.Jim Meyering
2000-12-16(main): Rename locals, user/group, to uid/gid.Jim Meyering
2000-12-15(main): Reflect renaming: s/dereference/change_symlinks/.Jim Meyering
2000-12-15(enum Dereference_symlink): rename member: s/change_symlinks/dereference/Jim Meyering
2000-12-15Declare lstat.Jim Meyering
Rename change_symlinks member to `dereference' and use the DEREF_* enum values. (describe_change): Merge the chgrp and chown switch statements. Use xmalloc to form the `user:group' string. (change_file_owner): Record (and later, use) is_symlink and is_directory from the lstat stats, in order to control whether we operate on symlinks and whether (with -R) we traverse symlinks to directories. When dereferencing, use open/fchown (rather than chown) on symlinks.
2000-12-10give a better diagnostic when only the group is being changedJim Meyering
2000-12-09(chopt_free): don't free anythingJim Meyering
2000-12-09Include "chown-core.h".Jim Meyering
[enum Change_status, enum Verbosity]: Remove declarations. Remove decls of globals that are now part of struct Chown_option. Remove decl of xstat. (describe_change): Remove function. (change_file_group): Likewise. (change_dir_group): Likewise. (parse_group): Don't set global, groupname, here... (main): ... instead, initialize `chopt.group_name' here. Initialize chopt and update uses of the now-members. Set group_name also when it's obtained via a --reference=FILE option. Call change_file_owner (with -1 for uids), not change_file_group.
2000-12-09add 3 more prototypesJim Meyering
2000-12-09Include <pwd.h>, <grp.h>, and "xalloc.h".Jim Meyering
[!_POSIX_VERSION]: Declare getgrnam and getgrgid. (gid_to_name): New function. (uid_to_name): Likewise. (chopt_free): Likewise.
2000-12-09Don't include pwd.h or grp.h -- no longer needed.Jim Meyering
Include chown-core.h. [enum Change_status, enum Verbosity]: Remove declarations. Remove decls of globals that are now part of struct Chown_option. (describe_change): Remove function. (change_file_owner): Likewise. (change_dir_owner): Likewise. (main): Initialize chopt and update uses of the now-members. Set user_name and group_name also when they're obtained via a --reference=FILE option. Pass `chopt' to change_file_owner.
2000-12-09*** empty log message ***Jim Meyering
2000-12-09*** empty log message ***Jim Meyering
2000-12-09(change_file_owner): Restore special file permissionJim Meyering
bits, since calling chown resets them on some systems. Reported by Matt Perry.
2000-12-08Include xalloc.h.Jim Meyering
(main): Use dir_name rather than the underlying dir_name_r. The former now handles cwd-relative names with drive-letter prefixes.
2000-12-07(address_base): Declare to be static.Jim Meyering
2000-12-07(address_base, address_pad_len): New var.Jim Meyering
(output_address_fmt_string, address_fmt_buffer, address_pad): Remove. (flag_pseudo_start): Now int, not long int. (pseudo_offset): Now off_t, not long int. (n_specs, n_specs_allocated): Now size_t, not unsigned int. (format_address, format_address_none, format_address_std, format_address_label): Now accepts an extra char argument (an extra char to print if nonzero), and prints instead of returning a string. All callers changed. (bytes_per_block): Now size_t, not int. (format_address_none): Do not even print the extra char argument. This simplifies the callers. (format_address_std, format_address_label): Print off_t ourself instead of trying to use autoconfigured format. This is faster and more portable. (format_address_paren): New function. (dump): Remove unnecessary cast. (expand_address_fmt): Remove. (main): Use size_t, off_t, etc. instead of builtin types where this is advisable. Adjust to above changes. Remove unnecessary cast.
2000-12-03(gobble_file) [USE_ACL]: Set have_acl member unconditionallyJim Meyering
to avoid uninitialized memory reference via FILE_HAS_ACL.
2000-12-03remove instrumentationJim Meyering