Lines Matching refs:len
244 size_t len; /* Number of bytes */ member
1461 size_t len = color_indicator[type].len; in is_colored() local
1463 return ! (len == 0 in is_colored()
1464 || (len == 1 && STRNCMP_LIT (s, "0") == 0) in is_colored()
1465 || (len == 2 && STRNCMP_LIT (s, "00") == 0)); in is_colored()
1833 if (!(color_indicator[C_LEFT].len == 2 in main()
1835 && color_indicator[C_RIGHT].len == 1 in main()
2790 state = (get_funky_string (&buf, &p, true, &ext->ext.len) in parse_ls_color()
2825 &color_indicator[ind_no].len) in parse_ls_color()
2839 state = (get_funky_string (&buf, &p, false, &ext->seq.len) in parse_ls_color()
2886 if (e2->ext.len < SIZE_MAX && e1->ext.len == e2->ext.len) in parse_ls_color()
2888 if (memcmp (e1->ext.string, e2->ext.string, e1->ext.len) == 0) in parse_ls_color()
2889 e2->ext.len = SIZE_MAX; /* Ignore */ in parse_ls_color()
2891 e1->ext.len) == 0) in parse_ls_color()
2895 e2->ext.len = SIZE_MAX; /* Ignore */ in parse_ls_color()
2897 else if (e1->seq.len == e2->seq.len in parse_ls_color()
2899 e1->seq.len) == 0) in parse_ls_color()
2901 e2->ext.len = SIZE_MAX; /* Ignore */ in parse_ls_color()
2915 if (color_indicator[C_LINK].len == 6 in parse_ls_color()
3371 size_t len = quotearg_buffer (test, sizeof test , name, -1, in needs_quoting() local
3373 return *name != *test || strlen (name) != len; in needs_quoting()
3618 int len = mbswidth (human_readable (blocks, buf, human_output_opts, in gobble_file() local
3621 if (block_size_width < len) in gobble_file()
3622 block_size_width = len; in gobble_file()
3629 int len = format_user_width (f->stat.st_uid); in gobble_file() local
3630 if (owner_width < len) in gobble_file()
3631 owner_width = len; in gobble_file()
3636 int len = format_group_width (f->stat.st_gid); in gobble_file() local
3637 if (group_width < len) in gobble_file()
3638 group_width = len; in gobble_file()
3643 int len = format_user_width (f->stat.st_author); in gobble_file() local
3644 if (author_width < len) in gobble_file()
3645 author_width = len; in gobble_file()
3651 int len = strlen (f->scontext); in gobble_file() local
3652 if (scontext_width < len) in gobble_file()
3653 scontext_width = len; in gobble_file()
3666 int len = strlen (umaxtostr (major (f->stat.st_rdev), buf)); in gobble_file() local
3667 if (major_device_number_width < len) in gobble_file()
3668 major_device_number_width = len; in gobble_file()
3669 len = strlen (umaxtostr (minor (f->stat.st_rdev), buf)); in gobble_file()
3670 if (minor_device_number_width < len) in gobble_file()
3671 minor_device_number_width = len; in gobble_file()
3672 len = major_device_number_width + 2 + minor_device_number_width; in gobble_file()
3673 if (file_size_width < len) in gobble_file()
3674 file_size_width = len; in gobble_file()
3680 int len = mbswidth (human_readable (size, buf, in gobble_file() local
3684 if (file_size_width < len) in gobble_file()
3685 file_size_width = len; in gobble_file()
3693 int len = strlen (umaxtostr (f->stat.st_ino, buf)); in gobble_file() local
3694 if (inode_number_width < len) in gobble_file()
3695 inode_number_width = len; in gobble_file()
4218 size_t len = align_nstrftime (buf, sizeof buf, false, in long_time_expected_width() local
4220 if (len != 0) in long_time_expected_width()
4221 width = mbsnwidth (buf, len, MBSWIDTH_FLAGS); in long_time_expected_width()
4535 size_t len = 0; in quote_name_buf() local
4546 len = quotearg_buffer (buf, bufsize, name, -1, options); in quote_name_buf()
4547 if (bufsize <= len) in quote_name_buf()
4549 buf = xmalloc (len + 1); in quote_name_buf()
4550 quotearg_buffer (buf, len + 1, name, -1, options); in quote_name_buf()
4553 quoted = (*name != *buf) || strlen (name) != len; in quote_name_buf()
4557 len = strlen (name); in quote_name_buf()
4558 if (bufsize <= len) in quote_name_buf()
4559 buf = xmalloc (len + 1); in quote_name_buf()
4560 memcpy (buf, name, len + 1); in quote_name_buf()
4566 len = strlen (name); in quote_name_buf()
4576 char const *plimit = buf + len; in quote_name_buf()
4672 len = q - buf; in quote_name_buf()
4677 char const *plimit = buf + len; in quote_name_buf()
4685 displayed_width = len; in quote_name_buf()
4692 displayed_width = mbsnwidth (buf, len, MBSWIDTH_FLAGS); in quote_name_buf()
4698 char const *plimit = buf + len; in quote_name_buf()
4720 return len; in quote_name_buf()
4773 size_t len; in quote_name() local
4776 len = quote_name_buf (&buf, sizeof smallbuf, (char *) name, options, in quote_name()
4811 fwrite (buf + skip_quotes, 1, len - (skip_quotes * 2), stdout); in quote_name()
4813 dired_pos += len; in quote_name()
4822 putchar (*(buf + len - 1)); in quote_name()
4828 return len + pad; in quote_name()
4845 size_t len = quote_name (name, filename_quoting_options, f->quoted, in print_name_with_quoting() local
4860 && (start_col / line_length != (start_col + len - 1) / line_length)) in print_name_with_quoting()
4864 return len; in print_name_with_quoting()
4979 size_t len; /* Length of name */ in get_color_indicator() local
5060 len = strlen (name); in get_color_indicator()
5061 name += len; /* Pointer to final \0. */ in get_color_indicator()
5064 if (ext->ext.len <= len) in get_color_indicator()
5068 if (STREQ_LEN (name - ext->ext.len, ext->ext.string, in get_color_indicator()
5069 ext->ext.len)) in get_color_indicator()
5074 if (c_strncasecmp (name - ext->ext.len, ext->ext.string, in get_color_indicator()
5075 ext->ext.len) == 0) in get_color_indicator()
5113 fwrite (ind->string, ind->len, 1, stdout); in put_indicator()
5119 size_t len = 0; in length_of_file_name_and_frills() local
5123 len += 1 + (format == with_commas in length_of_file_name_and_frills()
5128 len += 1 + (format == with_commas in length_of_file_name_and_frills()
5136 len += 1 + (format == with_commas ? strlen (f->scontext) : scontext_width); in length_of_file_name_and_frills()
5138 len += fileinfo_name_width (f); in length_of_file_name_and_frills()
5143 len += (c != 0); in length_of_file_name_and_frills()
5146 return len; in length_of_file_name_and_frills()
5235 size_t len = line_length ? length_of_file_name_and_frills (f) : 0; in print_with_separator() local
5242 || ((pos + len + 2 < line_length) in print_with_separator()
5243 && (pos <= SIZE_MAX - len - 2))) in print_with_separator()
5259 pos += len; in print_with_separator()