int quote = 0;
int output_tabs = 1;
-/* If non-zero, call cat, otherwise call simple_cat to do the actual work. */
+/* If nonzero, call cat, otherwise call simple_cat to do the actual work. */
int options = 0;
- /* If non-zero, display usage information and exit. */
+ /* If nonzero, display usage information and exit. */
static int show_help;
- /* If non-zero, print the version on standard output then exit. */
+ /* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* The name this program was run with. */
char *program_name;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* If nonzero, print lines that are found in both files. */
static int both;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* Number of elements in `controls'. */
static unsigned int control_used;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
static enum operating_mode operating_mode;
-/* If non-zero do not output lines containing no delimeter characters.
+/* If nonzero do not output lines containing no delimeter characters.
Otherwise, all such lines are printed. This option is valid only
with field mode. */
static int suppress_non_delimited;
/* Nonzero if we have ever read standard input. */
static int have_read_stdin;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
to its starting index. FIELDSTR should be composed of one or more
numbers or ranges of numbers, separated by blanks or commas.
Incomplete ranges may be given: `-m' means `1-m'; `n-' means `n'
- through end of line. Return non-zero if FIELDSTR contains at least
+ through end of line. Return nonzero if FIELDSTR contains at least
one field specification, zero otherwise. */
/* FIXME-someday: What if the user wants to cut out the 1,000,000-th field
/* Status to return to the system. */
static int exit_status;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* The name this program was run with. */
const char *program_name;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help = 0;
-/* If non-zero, print the version on standard output and exit. */
+/* If nonzero, print the version on standard output and exit. */
static int show_version = 0;
/* Option values. */
after the current paragraph. */
static int next_prefix_indent;
-/* If non-zero, the length of the last line output in the current
+/* If nonzero, the length of the last line output in the current
paragraph, used to charge for raggedness at the split point for long
paragraphs chosen by fmt_paragraph(). */
static int last_line_length;
/* If nonzero, at least one of the files we read was standard input. */
static int have_read_stdin;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* Have we ever read standard input? */
static int have_read_stdin;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* Convert a single field specifier string, S, to a *FILE_INDEX, *FIELD_INDEX
pair. In S, the field index string is 1-based; *FIELD_INDEX is zero-based.
If S is valid, return zero. Otherwise, give a diagnostic, don't update
- *FILE_INDEX or *FIELD_INDEX, and return non-zero. */
+ *FILE_INDEX or *FIELD_INDEX, and return nonzero. */
static int
decode_field_spec (const char *s, int *file_index, int *field_index)
}
/* Add the comma or blank separated field spec(s) in STR to `outlist'.
- Return non-zero to indicate failure. */
+ Return nonzero to indicate failure. */
static int
add_field_list (const char *c_str)
/* Nonzero if we have ever read standard input. */
static int have_read_stdin;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* The number of input bytes to skip before formatting and writing. */
static off_t n_bytes_to_skip = 0;
-/* When non-zero, MAX_BYTES_TO_FORMAT is the maximum number of bytes
+/* When nonzero, MAX_BYTES_TO_FORMAT is the maximum number of bytes
to be read and formatted. Otherwise all input is formatted. */
static int limit_bytes_to_format = 0;
/* The maximum number of bytes that will be formatted. This
- value is used only when LIMIT_BYTES_TO_FORMAT is non-zero. */
+ value is used only when LIMIT_BYTES_TO_FORMAT is nonzero. */
static off_t max_bytes_to_format;
-/* When non-zero and two or more consecutive blocks are equal, format
+/* When nonzero and two or more consecutive blocks are equal, format
only the first block and output an asterisk alone on the following
line to indicate that identical blocks have been elided. */
static int abbreviate_duplicate_blocks = 1;
/* The input stream associated with the current file. */
static FILE *in_stream;
-/* If non-zero, at least one of the files we read was standard input. */
+/* If nonzero, at least one of the files we read was standard input. */
static int have_read_stdin;
#define LONGEST_INTEGRAL_TYPE long int
#define MAX_FP_TYPE_SIZE sizeof(LONG_DOUBLE)
static enum size_spec fp_type_size[MAX_FP_TYPE_SIZE + 1];
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
unsigned long integer value. If S points to a non-digit set *P to S,
*VAL to 0, and return 0. Otherwise, accumulate the integer value of
the string of digits. If the string of digits represents a value
- larger than ULONG_MAX, don't modify *VAL or *P and return non-zero.
+ larger than ULONG_MAX, don't modify *VAL or *P and return nonzero.
Otherwise, advance *P to the first non-digit after S, set *VAL to
the result of the conversion and return zero. */
description of that format in *TSPEC, make *NEXT point at the character
following the just-decoded format (if *NEXT is non-NULL), and return
zero. If S is not valid, don't modify *NEXT or *TSPEC and return
- non-zero. For example, if S were "d4afL" *NEXT would be set to "afL"
+ nonzero. For example, if S were "d4afL" *NEXT would be set to "afL"
and *TSPEC would be
{
fmt = SIGNED_DECIMAL;
/* Decode the POSIX-style od format string S. Append the decoded
representation to the global array SPEC, reallocating SPEC if
- necessary. Return zero if S is valid, non-zero otherwise. */
+ necessary. Return zero if S is valid, nonzero otherwise. */
static int
decode_format_string (const char *s)
file pointer IN_STREAM to position N_SKIP in the concatenation of
those files. If any file operation fails or if there are fewer than
N_SKIP bytes in the combined input, give an error message and return
- non-zero. When possible, use seek- rather than read operations to
+ nonzero. When possible, use seek- rather than read operations to
advance IN_STREAM. A file name of "-" is interpreted as standard
input. */
}
/* Test whether there have been errors on in_stream, and close it if
- it is not standard input. Return non-zero if there has been an error
+ it is not standard input. Return nonzero if there has been an error
on in_stream or stdout; return zero otherwise. This function will
report more than one error only if both a read and a write error
have occurred. */
the list. Then try to read a byte from the newly opened file.
Repeat if necessary until *FILE_LIST is NULL. When EOF is reached
for the last file in FILE_LIST, set *C to EOF and return. Subsequent
- calls do likewise. The return value is non-zero if any errors
+ calls do likewise. The return value is nonzero if any errors
occured, zero otherwise. */
static int
Repeat if necessary until *FILE_LIST is NULL. Set *N_BYTES_IN_BUFFER
to the number of bytes read. If an error occurs, it will be detected
through ferror when the stream is about to be closed. If there is an
- error, give a message but continue reading as usual and return non-zero.
+ error, give a message but continue reading as usual and return nonzero.
Otherwise return zero. */
static int
multiple of all format spec sizes. Write the final block. Finally,
write on a line by itself the offset of the byte after the last byte
read. Accumulate return values from calls to read_block and
- check_and_close, and if any was non-zero, return non-zero.
+ check_and_close, and if any was nonzero, return nonzero.
Otherwise, return zero. */
static int
A string constant is a run of at least `string_min' ASCII
graphic (or formatting) characters terminated by a null.
Based on a function written by Richard Stallman for a
- pre-POSIX version of od. Return non-zero if an error
+ pre-POSIX version of od. Return nonzero if an error
occurs. Otherwise, return zero. */
static int
/* A pointer to the character after the end of `delims'. */
static char *delim_end;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
Important for converting tabs to spaces on input. */
static int input_position;
-/* Count number of failed opens so we can exit with non-zero
+/* Count number of failed opens so we can exit with nonzero
status if there were any. */
static int failed_opens = 0;
/* True means we truncate lines longer than chars_per_column. */
static int truncate_lines = FALSE;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* Descriptor on which output file is open. */
static int output_desc;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
-/* If non-zero, print a diagnostic on standard error just before each
+/* If nonzero, print a diagnostic on standard error just before each
output file is opened. */
static int verbose;
/* Right-rotate 32-bit integer variable C. */
#define ROTATE_RIGHT(c) if ((c) & 01) (c) = ((c) >>1) + 0x8000; else (c) >>= 1;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* The name of a temporary file containing a copy of pipe input. */
static char *tempfile;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* Nonzero if we have ever read standard input. */
static int have_read_stdin;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
/* The number of [c*] and [c*0] constructs that appear in this spec. */
int n_indefinite_repeats;
- /* If n_indefinite_repeats is non-zero, this points to the List_element
+ /* If n_indefinite_repeats is nonzero, this points to the List_element
corresponding to the last [c*] or [c*0] construct encountered in
this spec. Otherwise it is undefined. */
struct List_element *indefinite_repeat_element;
size_t len;
};
-/* Return non-zero if the Ith character of escaped string ES matches C
+/* Return nonzero if the Ith character of escaped string ES matches C
and is not escaped itself. */
#define ES_MATCH(ES, I, C) ((ES)->s[(I)] == (C) && !(ES)->escaped[(I)])
/* The name by which this program was run. */
char *program_name;
-/* When non-zero, each sequence in the input of a repeated character
+/* When nonzero, each sequence in the input of a repeated character
(call it c) is replaced (in the output) by a single occurrence of c
for every c in the squeeze set. */
static int squeeze_repeats = 0;
-/* When non-zero, removes characters in the delete set from input. */
+/* When nonzero, removes characters in the delete set from input. */
static int delete = 0;
/* Use the complement of set1 in place of set1. */
static int complement = 0;
-/* When non-zero, this flag causes GNU tr to provide strict
+/* When nonzero, this flag causes GNU tr to provide strict
compliance with POSIX draft 1003.2.11.2. The POSIX spec
says that when -d is used without -s, string2 (if present)
must be ignored. Silently ignoring arguments is a bad idea.
The default GNU behavior is to give a usage message and exit.
- Additionally, when this flag is non-zero, tr prints warnings
+ Additionally, when this flag is nonzero, tr prints warnings
on stderr if it is being used in a manner that is not portable.
Applicable warnings are given by default, but are suppressed
if the environment variable `POSIXLY_CORRECT' is set, since
being POSIX conformant means we can't issue such messages.
Warnings on the following topics are suppressed when this
- variable is non-zero:
+ variable is nonzero:
1. Ambiguous octal escapes. */
static int posix_pedantic;
corresponding character in string2. That is, string1 is effectively
truncated to the length of string2.
- When non-zero, this flag causes GNU tr to imitate the behavior
+ When nonzero, this flag causes GNU tr to imitate the behavior
of System V tr when translating with string1 longer than string2.
The default is to emulate BSD tr. This flag is ignored in modes where
no translation is performed. Emulating the System V tr
two specification strings and the delete switch is not given. */
static char xlate[N_CHARS];
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const long_options[] =
exit (status);
}
-/* Return non-zero if the character C is a member of the
+/* Return nonzero if the character C is a member of the
equivalence class containing the character EQUIV_CLASS. */
static int
return (equiv_class == c);
}
-/* Return non-zero if the character C is a member of the
+/* Return nonzero if the character C is a member of the
character class CHAR_CLASS. */
static int
/* Perform the first pass over each range-spec argument S, converting all
\c and \ddd escapes to their one-byte representations. The conversion
is done in-place, so S must point to writable storage. If an invalid
- quote sequence is found print an error message and return non-zero.
+ quote sequence is found print an error message and return nonzero.
Otherwise set *LEN to the length of the resulting string and return
zero. The resulting array of characters may contain zero-bytes;
however, on input, S is assumed to be null-terminated, and hence
/* Append a newly allocated structure representing the range
of characters from FIRST to LAST to the specification list LIST.
- Return non-zero if LAST precedes FIRST in the collating sequence,
+ Return nonzero if LAST precedes FIRST in the collating sequence,
zero otherwise. This means that '[c-c]' is acceptable. */
static int
/* If CHAR_CLASS_STR is a valid character class string, append a
newly allocated structure representing that character class to the end
of the specification list LIST and return 0. If CHAR_CLASS_STR is not
- a valid string return non-zero. */
+ a valid string return nonzero. */
static int
append_char_class (struct Spec_list *list,
the length of that string, LEN, if LEN is exactly one, append
a newly allocated structure representing the specified
equivalence class to the specification list, LIST and return zero.
- If LEN is not 1, return non-zero. */
+ If LEN is not 1, return nonzero. */
static int
append_equiv_class (struct Spec_list *list,
/* Search forward starting at START_IDX for the 2-char sequence
(PRE_BRACKET_CHAR,']') in the string P of length P_LEN. If such
a sequence is found, set *RESULT_IDX to the index of the first
- character and return non-zero. Otherwise return zero. P may contain
+ character and return nonzero. Otherwise return zero. P may contain
zero bytes. */
static int
containing embedded zero bytes, to a long integer value.
If the string represents a negative value, a value larger
than LONG_MAX, or if all LEN characters do not represent a
- valid integer, return non-zero and do not modify *VAL.
+ valid integer, return nonzero and do not modify *VAL.
Otherwise, return zero and set *VAL to the converted value. */
static int
return -1; /* No bracket found. */
}
-/* Return non-zero if the string at ES->s[IDX] matches the regular
+/* Return nonzero if the string at ES->s[IDX] matches the regular
expression `\*[0-9]*\]', zero otherwise. To match, the `*' and
the `]' must not be escaped. */
}
free (opnd_str);
- /* Return non-zero if append_*_class reports a problem. */
+ /* Return nonzero if append_*_class reports a problem. */
if (parse_failed)
return 1;
else
one converts all \c and \ddd escapes to their one-byte representations.
The second constructs a linked specification list, SPEC_LIST, of the
characters and constructs that comprise the argument string. If either
- of these passes detects an error, this function returns non-zero. */
+ of these passes detects an error, this function returns nonzero. */
static int
parse_str (const unsigned char *s, struct Spec_list *spec_list)
/* Initialize a boolean membership set IN_SET with the character
values obtained by traversing the linked list of constructs S
using the function `get_next'. If COMPLEMENT_THIS_SET is
- non-zero the resulting set is complemented. */
+ nonzero the resulting set is complemented. */
static void
set_initialize (struct Spec_list *s, int complement_this_set, SET_TYPE *in_set)
/* Status to return to the system. */
static int exit_status;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* Which lines to output. */
static enum output_mode mode;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exit. */
+/* If nonzero, print the version on standard output then exit. */
static int show_version;
static struct option const longopts[] =
/* The error code to return to the system. */
static int exit_status;
-/* If non-zero, display usage information and exit. */
+/* If nonzero, display usage information and exit. */
static int show_help;
-/* If non-zero, print the version on standard output then exits. */
+/* If nonzero, print the version on standard output then exits. */
static int show_version;
static struct option const longopts[] =