<feed xmlns='http://www.w3.org/2005/Atom'>
<title>src/lib/libutil++/tests/Makefile, branch main</title>
<subtitle>FreeBSD source tree</subtitle>
<id>https://cgit-dev.freebsd.org/src/atom?h=main</id>
<link rel='self' href='https://cgit-dev.freebsd.org/src/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/'/>
<updated>2025-08-04T19:38:07Z</updated>
<entry>
<title>libutil++: Add freebsd::pidfile wrapper class around struct pidfh</title>
<updated>2025-08-04T19:38:07Z</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2025-08-04T19:38:07Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=7be913e00d79b3bf740049797fbc3f6ab8193995'/>
<id>urn:sha1:7be913e00d79b3bf740049797fbc3f6ab8193995</id>
<content type='text'>
This class wraps the pidfile_* API from libutil.  The destructor calls
pidfile_remove() when an object is destroyed.  This class is similar
to std::unique_ptr&lt;&gt; in that it retains exclusive ownership of the
pidfh object.

In addition to release and reset methods, write, close, and fileno
methods are provided as wrappers for pidfile_*.

Sponsored by:	Chelsio Communications
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1794
</content>
</entry>
<entry>
<title>libutil++: New library containing C++ utility classes for use in base</title>
<updated>2025-08-04T19:38:06Z</updated>
<author>
<name>John Baldwin</name>
<email>jhb@FreeBSD.org</email>
</author>
<published>2025-08-04T19:38:06Z</published>
<link rel='alternate' type='text/html' href='https://cgit-dev.freebsd.org/src/commit/?id=b3127a2dc25ac63cae8e33e6f3dbd3580644fe52'/>
<id>urn:sha1:b3127a2dc25ac63cae8e33e6f3dbd3580644fe52</id>
<content type='text'>
- freebsd::FILE_up is a wrapper class for std::unique_ptr&lt;&gt; for FILE
  objects which uses a custom deleter that calls fclose().

- freebsd::malloc_up&lt;T&gt; is a wrapper class for std::unique_ptr&lt;&gt; which
  uses a custom deleter that calls free().  It is useful for pointers
  allocated by malloc() such as strdup().

- The freebsd::stringf() functions return a std::string constructed
  using a printf format string.

  The current implementation of freebsd::stringf() uses fwopen() where
  the write function appends to a std::string.

Sponsored by:	Chelsio Communications
Pull Request:	https://github.com/freebsd/freebsd-src/pull/1794
</content>
</entry>
</feed>
