Age | Commit message (Collapse) | Author |
|
|
|
(MAX_ADDRESS_LENGTH): Don't hard-code as a literal.
Rather, define in terms of the type, off_t.
(string_min): Declare to be of type size_t.
(flag_dump_strings): Declare to be of type int.
(print_s_char): Declare the n_bytes parameter and the local, `i',
to be of type off_t.
(print_char): Likewise.
(print_s_short): Likewise.
(print_short): Likewise.
(print_int): Likewise.
(print_long): Likewise.
(print_long_long): Likewise.
(print_float): Likewise.
(print_double): Likewise.
(print_long_double): Likewise.
(dump_hexl_mode_trailer): Likewise.
(print_named_ascii): Likewise.
(print_ascii): Likewise.
(write_block): Likewise.
(print_ascii): Declare local, `print_function' with a prototype.
Change a few `>' comparisons to the equivalent `<' form.
(parse_options): Declare `tmp' to be of type uintmax_t.
Use xstrtoumax, not xstrtoul.
Fail if the specified offset if larger than OFF_T_MAX.
(dump_strings): Declare local `i' to be of type size_t.
Remove the now-unnecessary cast-to-off_t.
(main) [IF_LINT]: Initialize desired_width to avoid a warning.
Declare `tmp' to be of type uintmax_t.
Use xstrtoumax, not xstrtoul.
Fail if minimum string length is larger than SIZE_MAX.
Fail if specified width is larger than ULONG_MAX.
|
|
(format_address): Use off_t, not long unsigned_int as the
parameter type.
(format_address_none): Likewise. Mark parameter as unused.
(format_address_std): Likewise.
(format_address_label): Likewise.
(print_ascii): Mark format string parameter as unused.
(write_block): Use off_t, not long unsigned_int as offset type.
(expand_address_fmt): New function.
(main): Use it to expand each address format string template.
Reported by Mark Nudelman, via Andreas Jaeger.
|
|
This should be portable, as we seek before doing any I/O.
(fseeko): Remove; no longer used.
|
|
|
|
Add support for printing data as unsigned
long long integers.
|
|
|
|
(main): Likewise.
|
|
|
|
* src/sys2.h (MIN, MAX): Define here instead.
|
|
|
|
|
|
|
|
|
|
|
|
[long_options]: Remove the "help" and "version" entries.
Remove declarations of show_help and show_version.
(main): Use parse_long_options, including author name(s).
Remove the show_version and show_help blocks.
|
|
|
|
|
|
stream to binary mode.
|
|
|
|
|
|
|
|
Remove definitions of those symbols.
* src/csplit.c: Move inclusion of regex.h/rx.h to follow system.h
since it now includes limit.h which defines RE_DUP_MAX.
* src/nl.c: Likewise.
* src/tac.c: Likewise.
|
|
|
|
(skip): Use fseeko if available. Don't use lseek; it causes
the stdio stream to become out of sync with respect to the
underyling file descriptor.
From Paul Eggert.
|
|
(decode_format_string): Cast first arg of xrealloc to char*.
|
|
|
|
|
|
|
|
(dump_hexl_mode_trailer): Rename from dump_string_trailer.
Use fputs and putchar instead of trivial or %-less printfs.
(decode_one_format): Parenthesize each field_width assignment in an
argument list to make the side effect a little more apparent.
(write_block): Use fputs and putchar instead of trivial or %-less printfs.
(dump_strings): Cast string_min to off_t to avoid long-standing warning.
|
|
|
|
|
|
|
|
being more than three arguments if there are *no* arguments specified.
Reported by Jochen Hein.
|
|
|
|
|
|
|
|
*) 0' as last parameter in getopt_long call.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
(main): Compare against LONG_MAX rather than OFF_T_MAX.
|
|
so the left operand of the << isn't signed.
From Kaveh Ghazi.
|
|
corresponding to unsigned long, SIZE.
|
|
Give a specific diagnostic for invalid format spec here rather
than an overly general one from caller's caller.
(decode_format_string): Update caller.
(main): Don't give diagnostic here when decode_format_string fails.
Remove assertions that could fail on some Crays because they don't
have a two-byte type.
Johan Danielsson (joda@pdc.kth.se) reported the failed assertions.
|
|
|