]> git.ipfire.org Git - thirdparty/squid.git/commit
Simplify appending SBuf to String (#2108)
authorAlex Rousskov <rousskov@measurement-factory.com>
Mon, 30 Jun 2025 20:32:16 +0000 (20:32 +0000)
committerSquid Anubis <squid-anubis@squid-cache.org>
Wed, 2 Jul 2025 01:50:15 +0000 (01:50 +0000)
commite93eda7ed9b291a1d968d74e2cc0d4016ea7e682
treead50d0d86ca070c6cab83fb99c550b24017ee1c6
parent0b514968b6d7de6f4115fd56247ec714b9f70df8
Simplify appending SBuf to String (#2108)

There is still a lot of code that uses legacy String class, and an
increasing amount of code that has to append modern SBufs to Strings.

SBuf handles NUL bytes better than String. With respect to handling NUL
bytes, the new append() method is as (un)safe as the existing explicit
size-based one (that callers tend to use prior to these changes anyway).
src/SquidString.h
src/String.cc
src/clients/FtpGateway.cc
src/ipc/Port.cc
src/ipc/mem/Segment.cc