File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed
lldb/tools/debugserver/source Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -1643,7 +1643,9 @@ rnb_err_t RNBRemote::HandlePacket_qLaunchSuccess(const char *p) {
1643
1643
return SendPacket (" OK" );
1644
1644
std::ostringstream ret_str;
1645
1645
std::string status_str;
1646
- ret_str << " E" << m_ctx.LaunchStatusAsString (status_str);
1646
+ std::string error_quoted = binary_encode_string
1647
+ (m_ctx.LaunchStatusAsString (status_str));
1648
+ ret_str << " E" << error_quoted;
1647
1649
1648
1650
return SendPacket (ret_str.str ());
1649
1651
}
@@ -2677,8 +2679,9 @@ std::string cstring_to_asciihex_string(const char *str) {
2677
2679
std::string hex_str;
2678
2680
hex_str.reserve (strlen (str) * 2 );
2679
2681
while (str && *str) {
2682
+ uint8_t c = *str++;
2680
2683
char hexbuf[5 ];
2681
- snprintf (hexbuf, sizeof (hexbuf), " %02x" , *str++ );
2684
+ snprintf (hexbuf, sizeof (hexbuf), " %02x" , c );
2682
2685
hex_str += hexbuf;
2683
2686
}
2684
2687
return hex_str;
You can’t perform that action at this time.
0 commit comments