Skip to content

Commit

Permalink
record_accessor: allow single char for flb_ra_translate(fluent#7330)
Browse files Browse the repository at this point in the history
Signed-off-by: Takahiro Yamashita <[email protected]>
  • Loading branch information
nokute78 committed May 6, 2023
1 parent 8f59338 commit 8a696be
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/flb_record_accessor.c
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ static int ra_parse_buffer(struct flb_record_accessor *ra, flb_sds_t buf)
}

/* Append remaining string */
if (i - 1 > end && pre < i) {
if ((i - 1 > end && pre < i) || i == 1 /*allow single character*/) {
end = flb_sds_len(buf);
rp_str = ra_parse_string(ra, buf, pre, end);
if (rp_str) {
Expand Down

0 comments on commit 8a696be

Please sign in to comment.