DEVCTL_SAFE_QUOTE_SB(9)
πΈ NAME πΈ
Okay bestie, this is the DEVCTL_SAFE_QUOTE_SB(9) page from the Kernel Developer's Manual β¨ β and the function is devctl_safe_quote_sb: it inserts a string, properly quoted, into a sbuf. Periodt π
.
β¨ SYNOPSIS β¨
#include <sys/devctl.h>
#include <sys/sbuf.h>
void
devctl_safe_quote_sb(struct sbuf *sb, const char *src);
π DESCRIPTION π
So hereβs the vibe: copy the string from src into sb. Thatβs the main-character move π.
When it does that, these rules are non-negotiable:
- 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) protocol requires a quoted string to be quoted this exact way. This routine is the one that centralizes this knowledge, so it lives in one place instead of being scattered everywhere. Slay π«Ά.
π¦ SEE ALSO π¦
π AUTHORS π
This manual page was written by M. Warner Losh. Iconic π.
Thatβs the whole page, bestie π β the footer source/version says Debian, and the date is September 22, 2020. DEVCTL_SAFE_QUOTE_SB(9) signing off π.
π¦ where this page comes from
- freebsd 14.5: base 14.5
- freebsd 15.1: base 15.1
- nixpkgs unstable: source
- Copyright (c) 2020 M Warner Losh
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms