最近在学习谷歌的开源浏览器 Cef 框架,
//std::string old_overflow;
if (max_write < str_size) {
overflow_ += std::string(str + max_write, str_size - max_write);
}
然后我改成了这样
//std::string old_overflow;
if (max_write < str_size) {
std::string test = std::string(str + max_write, str_size - max_write);
overflow_ += test;
}
结果在打开网页时,往来的代码没有问题,我改的就要反复刷新好几次才会出现网页,我也就是把一行代码拆开写了,为啥会这样?