---
name: "devctl_safe_quote_sb"
section: "9"
platform: "freebsd"
package: "base"
version: "16.0-CURRENT-20261027-61c70dc16a79"
release: "FreeBSD 16.0-CURRENT (2026-10-27)"
platforms: ["freebsd"]
url: "https://new.carta.tech/devctl_safe_quote_sb"
---

# devctl\_safe\_quote\_sb(9)

Insert a string, properly quoted, into a sbuf

## NAME

**devctl\_safe\_quote\_sb** – Insert a string, properly quoted, into a sbuf

## SYNOPSIS

**#include \<sys/devctl.h\>**

**#include \<sys/sbuf.h\>**

*void*\

**devctl\_safe\_quote\_sb**(*struct sbuf \*sb*, *const char \*src*);

## DESCRIPTION

Copy the string from *src* into *sb*. All backslash characters are doubled. All double quote characters ‘"’ are also preceded by a backslash. All other characters are copied without modification. The [devctl(4)](/devctl/4.md) protocol requires quoted string to be quoted thus. This routine centralizes this knowledge.

## SEE ALSO

[devd(8)](/devd/8.md)

## AUTHORS

This manual page was written by M. Warner Losh
