MXS-2569: Always terminate schemas with newlines
If the stored file didn't have a newline in the schema, the schema and the first row would be on the same line.
This commit is contained in:
parent
7673ee685d
commit
301b1b63ab
@ -586,6 +586,8 @@ GWBUF* read_avro_json_schema(std::string avrofile, std::string dir)
|
||||
std::stringstream ss;
|
||||
ss << file.rdbuf();
|
||||
std::string text = ss.str();
|
||||
mxs::rtrim(text);
|
||||
text += '\n';
|
||||
mxs::Buffer buffer(std::vector<uint8_t>(text.begin(), text.end()));
|
||||
rval = buffer.release();
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user