Page MenuHomeFreeBSD

kyua: Switch from std::auto_ptr<> to std::unique_ptr<>
ClosedPublic

Authored by jhb on Apr 11 2025, 6:00 PM.
Tags
None
Referenced Files
Unknown Object (File)
Sun, Mar 29, 4:41 AM
Unknown Object (File)
Sat, Mar 28, 11:54 AM
Unknown Object (File)
Mon, Mar 23, 7:12 PM
Unknown Object (File)
Thu, Mar 12, 9:45 PM
Unknown Object (File)
Mar 2 2026, 1:13 AM
Unknown Object (File)
Feb 25 2026, 5:46 AM
Unknown Object (File)
Feb 20 2026, 12:39 AM
Unknown Object (File)
Feb 18 2026, 10:05 PM
Subscribers

Details

Summary

A few places were assigning auto_ptr<>s depending on the ownership
handoff. These now use an explicit std::move() as required by
unique_ptr<>.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

jhb requested review of this revision.Apr 11 2025, 6:00 PM

A test VM is most of the way through a full kyua test run with this stack of changes applied and seems to be running fine.

Most of this change was mechanical (sed -e 's/auto_ptr/unique_ptr/') with a few places adjusted to use std::move() to fix compile errors.

This revision is now accepted and ready to land.Apr 24 2025, 12:22 AM