[SERVER-7506] RamLog and standard log should preserve utf8 encoding when truncating Created: 30/Oct/12 Updated: 27/Oct/21 Resolved: 27/Oct/21 |
|
| Status: | Closed |
| Project: | Core Server |
| Component/s: | Logging |
| Affects Version/s: | 2.0.7, 2.2.0 |
| Fix Version/s: | None |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Ben Becker | Assignee: | Geert Bosch |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||
| Participants: | |||||||||
| Description |
|
RamLog::write() only copies the first 255 bytes of a long string, but if the last two bytes are part of a utf-8 encoding (e.g. 0xd0 0x80), a RamLog consumer may spuriously fail to validate the string is utf-8. |