Copilot commented on code in PR #3575:
URL: https://github.com/apache/brpc/pull/3575#discussion_r4163931244
##########
src/brpc/policy/mysql/mysql.h:
##########
@@ -198,7 +198,10 @@ class MysqlResponse : public
NonreflectableMessage<MysqlResponse> {
// Returns PARSE_ERROR_NOT_ENOUGH_DATA if data in `buf' is not enough to
parse.
// Returns PARSE_ERROR_ABSOLUTELY_WRONG if the parsing
// failed.
- ParseError ConsumePartialIOBuf(butil::IOBuf& buf, bool is_auth,
MysqlStmtType stmt_type);
+ ParseError ConsumePartialIOBuf(butil::IOBuf& buf,
+ bool is_auth,
+ MysqlStmtType stmt_type,
+ bool protocol41 = true);
Review Comment:
Adding `protocol41` replaces this public method's C++ symbol; a default
argument preserves source calls, not binary compatibility. Prebuilt clients
using the old signature can fail to link or load after replacing the library.
`MysqlReply::ConsumePartialIOBuf` has the same break. Preserve both old
signatures with out-of-line wrappers that forward `protocol41=true`, and remove
the default argument from the new overloads to avoid ambiguous calls.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]