randint randmax = s->randmax;
randint choices = genmax + 1;
- for (;;)
+ while (1)
{
if (randmax < genmax)
{
static void
readsource (struct randread_source *s, unsigned char *p, size_t size)
{
- for (;;)
+ while (true)
{
size_t inbytes = fread (p, sizeof *p, size, s->source);
int fread_errno = errno;
{
size_t inbytes = isaac->buffered;
- for (;;)
+ while (true)
{
if (size <= inbytes)
{
/* Loop until the end of the file. */
- for (;;)
+ while (true)
{
/* Read a block of input. */
bpout = outbuf;
- for (;;)
+ while (true)
{
do
{
scan for chars that need conversion. */
if (show_nonprinting)
{
- for (;;)
+ while (true)
{
if (ch >= 32)
{
else
{
/* Not quoting, neither of -v, -e, or -t specified. */
- for (;;)
+ while (true)
{
if (ch == '\t' && show_tabs)
{
buf_alloc = xmalloc (buf_size + buf_alignment_slop);
buf = ptr_align (buf_alloc, buf_alignment);
- for (;;)
+ while (true)
{
word *wp = NULL;
line_start = b->buffer;
bytes_left = b->bytes_used;
- for (;;)
+ while (true)
{
line_end = memchr (line_start, '\n', bytes_left);
if (line_end == NULL)
if (p->offset >= 0)
{
- for (;;)
+ while (true)
{
line = find_line (++current_line);
if (line == NULL)
else
{
/* Buffer the lines. */
- for (;;)
+ while (true)
{
line = find_line (++current_line);
if (line == NULL)
/* Collect and store in RP the range end points.
It also sets EOL_RANGE_START if appropriate. */
- for (;;)
+ while (true)
{
if (*fieldstr == '-')
{
static ssize_t
iread (int fd, char *buf, size_t size)
{
- for (;;)
+ while (true)
{
ssize_t nread;
process_signals ();
{
int value = 0;
- for (;;)
+ while (true)
{
char const *strcomma = strchr (str, ',');
struct symbol_value const *entry;
/* Now walk up FILE's parents until we find another file system or /,
chdiring as we go. LAST_STAT holds stat information for the last place
we visited. */
- for (;;)
+ while (true)
{
struct stat st;
if (stat ("..", &st) < 0)
print_grand_total = false;
grand_fsu.fsu_blocksize = 1;
- for (;;)
+ while (true)
{
int oi = -1;
int c = getopt_long (argc, argv, "aB:iF:hHklmPTt:vx:", long_options,
human_options (getenv ("DU_BLOCK_SIZE"),
&human_output_opts, &output_block_size);
- for (;;)
+ while (true)
{
int oi = -1;
int c = getopt_long (argc, argv, "0abd:chHklmsxB:DLPSX:",
if (!fp)
return;
- for (;;)
+ while (true)
{
/* Input character, or EOF. */
int c;
if (tab_size)
next_tab_column = column + (tab_size - column % tab_size);
else
- for (;;)
+ while (true)
if (tab_index == first_free_tab)
{
next_tab_column = column + 1;
--f;
}
- for (;;)
+ while (true)
{
mpz_tdiv_qr_ui (q, r, t, 3);
if (mpz_cmp_ui (r, 0) != 0)
emit_ul_factor (3);
}
- for (;;)
+ while (true)
{
mpz_tdiv_qr_ui (q, r, t, 5);
if (mpz_cmp_ui (r, 0) != 0)
init_tokenbuffer (&tokenbuffer);
- for (;;)
+ while (true)
{
size_t token_length = readtoken (stdin, DELIM, sizeof (DELIM) - 1,
&tokenbuffer);
static int
get_space (FILE *f, int c)
{
- for (;;)
+ while (true)
{
if (c == ' ')
in_column++;
}
}
- for (;;)
+ while (true)
{
int oi = -1;
int c = getopt_long (argc, argv,
address_pad_len = 7;
flag_dump_strings = false;
- for (;;)
+ while (true)
{
uintmax_t tmp;
enum strtol_error s_err;
? xmalloc ((argc - 1) * sizeof (char *))
: NULL);
- for (;;)
+ while (true)
{
int oi = -1;
int c = getopt_long (argc, argv, short_options, long_options, &oi);
print_clump (p, chars, clump_buff);
- for (;;)
+ while (true)
{
c = getc (p->fp);
}
offset = 0;
- for (;;)
+ while (true)
{
/* How much to write this time? */
lim = sizeof r;
d = dest; /* Destination for generated pass list */
n = num; /* Passes remaining to fill */
- for (;;)
+ while (true)
{
k = *p++; /* Block descriptor word */
if (!k)
size cannot be allocated, repeatedly halve it until allocation
succeeds. The smaller allocation may hurt overall performance,
but that's better than failing. */
- for (;;)
+ while (true)
{
alloc += sizeof (struct line) - alloc % sizeof (struct line);
buf->buf = malloc (alloc);
buf->nlines = 0;
}
- for (;;)
+ while (true)
{
char *ptr = buf->buf + buf->used;
struct line *linelim = buffer_linelim (buf);
size_t hi = MONTHS_PER_YEAR;
char const *monthlim = month + len;
- for (;;)
+ while (true)
{
if (month == monthlim)
return 0;
int diff;
- for (;;)
+ while (true)
{
char const *translate = key->translate;
bool const *ignore = key->ignore;
#define CMP_WITH_IGNORE(A, B) \
do \
{ \
- for (;;) \
+ while (true) \
{ \
while (texta < lima && ignore[to_uchar (*texta)]) \
++texta; \
struct line const *lo, size_t nlo,
struct line const *hi, size_t nhi)
{
- for (;;)
+ while (true)
if (compare (lo - 1, hi - 1, false) <= 0)
{
*--t = *--lo;
try to merge into the output, and then merge as much as we can into a
temp file if we can't. Repeat. */
- for (;;)
+ while (true)
{
/* Merge directly into the output file if possible. */
FILE **fps;
files = xnmalloc (argc, sizeof *files);
- for (;;)
+ while (true)
{
/* Parse an operand as a file after "--" was seen; or if
pedantic and a file was seen, unless the POSIX version
error (EXIT_FAILURE, errno, "%s", infile);
bp_out = buf;
to_read = n_read;
- for (;;)
+ while (true)
{
if (to_read < to_write)
{
bp = bp_out = buf;
eob = bp + n_read;
*eob = '\n';
- for (;;)
+ while (true)
{
bp = memchr (bp, '\n', eob - bp + 1);
if (bp == eob)
if (sentinel_length)
match_start -= match_length1;
- for (;;)
+ while (true)
{
/* Search backward from `match_start' - 1 to `G_buffer' for a match
with `separator'; for speed, use strncmp if `separator' contains no
{
bool value = true;
- for (;;)
+ while (true)
{
value &= term ();
if (! (pos < argc && STREQ (argv[pos], "-a")))
{
bool value = false;
- for (;;)
+ while (true)
{
value |= and ();
if (! (pos < argc && STREQ (argv[pos], "-o")))
size_t i = 0;
size_t nr = 0;
- for (;;)
+ while (true)
{
size_t begin;
{
set_initialize (s1, complement, in_delete_set);
- for (;;)
+ while (true)
{
size_t nr = read_and_delete (io_buf, sizeof io_buf);
if (nr == 0)
xlate[i] = i;
s1->state = BEGIN_STATE;
s2->state = BEGIN_STATE;
- for (;;)
+ while (true)
{
/* When the previous pair identified case-converting classes,
advance S1 and S2 so that each points to the following
}
else
{
- for (;;)
+ while (true)
{
size_t bytes_read = read_and_xlate (io_buf, sizeof io_buf);
if (bytes_read == 0)
t = root;
s = p = root->right;
- for (;;)
+ while (true)
{
/* A2. Compare. */
a = strcmp (str, p->str);
allocate MAX_COLUMN_WIDTH bytes to store the blanks. */
pending_blank = xmalloc (max_column_width);
- for (;;)
+ while (true)
{
/* Input character, or EOF. */
int c;
next_tab_column =
column + (tab_size - column % tab_size);
else
- for (;;)
+ while (true)
if (tab_index == first_free_tab)
{
convert = false;
countmode = count_none;
delimit_groups = DM_NONE;
- for (;;)
+ while (true)
{
/* Parse an operand with leading "+" as a file after "--" was
seen; or if pedantic and a file was seen; or if not
argv[argc++] = bad_cast ("y");
}
- for (;;)
+ while (true)
{
int i;
for (i = optind; i < argc; i++)