mirror of https://github.com/aria2/aria2
ColorizedStreamBuf::str: Append character prefix to stream directly
parent
80528aa9ce
commit
03d5b4627b
|
@ -86,9 +86,7 @@ std::string ColorizedStreamBuf::str(bool color, size_t max) const
|
||||||
}
|
}
|
||||||
auto size = e.second.size();
|
auto size = e.second.size();
|
||||||
if (size > max) {
|
if (size > max) {
|
||||||
auto cut = e.second;
|
rv.write(e.second.c_str(), max);
|
||||||
cut.resize(max);
|
|
||||||
rv << cut;
|
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
rv << e.second;
|
rv << e.second;
|
||||||
|
|
Loading…
Reference in New Issue