| 755 | } |
| 756 | |
| 757 | static inline void |
| 758 | finish_current_line (uintmax_t field_idx, bool buffer_first_field, |
| 759 | idx_t *field_1_n_bytes, |
| 760 | bool found_any_selected_field, bool line_terminated) |
| 761 | { |
| 762 | if (field_idx == 1 && buffer_first_field) |
| 763 | { |
| 764 | if (!suppress_non_delimited |
| 765 | && (line_terminated || *field_1_n_bytes != 0)) |
| 766 | { |
| 767 | write_bytes (field_1_buffer, *field_1_n_bytes); |
| 768 | write_line_delim (); |
| 769 | } |
| 770 | *field_1_n_bytes = 0; |
| 771 | } |
| 772 | else if (field_idx != 1 || found_any_selected_field) |
| 773 | maybe_write_line_delim (found_any_selected_field, field_idx); |
| 774 | } |
| 775 | |
| 776 | static inline void |
| 777 | sync_byte_selection (uintmax_t byte_idx) |
no test coverage detected