Skip to content

Commit e7b5c29

Browse files
Addressed comments
Signed-off-by: Athish Pranav D <[email protected]>
1 parent e7b111b commit e7b5c29

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

src/flb_msgpack_append_message.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,7 @@ int flb_msgpack_append_map_to_record(char **result_buffer,
9393
msgpack_object_kv *new_map_entries[1];
9494
msgpack_object_kv message_entry;
9595
char *modified_data_buffer;
96-
int modified_data_size;
96+
int modified_data_size;
9797
size_t off = 0;
9898
int i;
9999
int result = FLB_MAP_NOT_MODIFIED;
@@ -123,10 +123,10 @@ int flb_msgpack_append_map_to_record(char **result_buffer,
123123

124124
message_entry.val = unpacker.data;
125125
result = flb_msgpack_expand_map(base_object_buffer,
126-
base_object_size,
127-
new_map_entries, 1,
128-
&modified_data_buffer,
129-
&modified_data_size);
126+
base_object_size,
127+
new_map_entries, 1,
128+
&modified_data_buffer,
129+
&modified_data_size);
130130
if (result == 0) {
131131
result = FLB_MAP_EXPAND_SUCCESS;
132132
*result_buffer = modified_data_buffer;

tests/runtime/filter_parser.c

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -879,15 +879,12 @@ void flb_test_filter_parser_hash_value_field()
879879
wait_with_timeout(2000, &output); /* waiting flush and ensuring data flush */
880880
TEST_CHECK_(output != NULL, "Expected output to not be NULL");
881881
if (output != NULL) {
882-
/* check original field is preserved */
882+
/* check hash value field present */
883883
expected = "\"parsed\":{\"INT\":\"100\",\"FLOAT\":\"0.5\",\"BOOL\":\"true\",\"STRING\":\"This is an example\"}";
884884
TEST_CHECK_(strstr(output, expected) != NULL, "Expected output to contain '%s', got '%s'", expected, output);
885885
/* check fields were extracted */
886886
expected = "\"INT\":\"100\",\"FLOAT\":\"0.5\",\"BOOL\":\"true\",\"STRING\":\"This is an example\"";
887887
TEST_CHECK_(strstr(output, expected) != NULL, "Expected output to contain '%s', got '%s'", expected, output);
888-
/* check other fields are preserved */
889-
// expected = "\"log\":\"An example\"";
890-
// TEST_CHECK_(strstr(output, expected) != NULL, "Expected output to contain '%s', got '%s'", expected, output);
891888
free(output);
892889
}
893890

0 commit comments

Comments
 (0)