'\" t .TH "SD_BUS_SLOT_SET_DESCRIPTION" "3" "" "systemd 252" "sd_bus_slot_set_description" .\" ----------------------------------------------------------------- .\" * Define some portability stuff .\" ----------------------------------------------------------------- .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .\" http://bugs.debian.org/507673 .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ .ie \n(.g .ds Aq \(aq .el .ds Aq ' .\" ----------------------------------------------------------------- .\" * set default formatting .\" ----------------------------------------------------------------- .\" disable hyphenation .nh .\" disable justification (adjust text to left margin only) .ad l .\" ----------------------------------------------------------------- .\" * MAIN CONTENT STARTS HERE * .\" ----------------------------------------------------------------- .SH "NAME" sd_bus_slot_set_description, sd_bus_slot_get_description \- Set or query the description of bus slot objects .SH "SYNOPSIS" .sp .ft B .nf #include .fi .ft .HP \w'int\ sd_bus_slot_set_description('u .BI "int sd_bus_slot_set_description(sd_bus_slot*\ " "slot" ", const\ char\ *" "description" ");" .HP \w'int\ sd_bus_slot_get_description('u .BI "int sd_bus_slot_get_description(sd_bus_slot*\ " "bus" ", const\ char\ **" "description" ");" .SH "DESCRIPTION" .PP \fBsd_bus_slot_set_description()\fR sets the description string that is used in logging to the specified string\&. The string is copied internally and freed when the bus slot object is deallocated\&. The \fIdescription\fR argument may be \fBNULL\fR, in which case the description is unset\&. .PP \fBsd_bus_slot_get_description()\fR returns a description string in \fIdescription\fR\&. If the string is not set, e\&.g\&. with \fBsd_bus_slot_set_description()\fR, and the slot is a bus match callback slot, the match string will be returned\&. Otherwise, \fB\-ENXIO\fR is returned\&. .SH "RETURN VALUE" .PP On success, these functions return 0 or a positive integer\&. On failure, they return a negative errno\-style error code\&. .SS "Errors" .PP Returned errors may indicate the following problems: .PP \fB\-EINVAL\fR .RS 4 An required argument is \fBNULL\fR\&. .RE .PP \fB\-ENXIO\fR .RS 4 The bus slot object has no description\&. .RE .PP \fB\-ENOMEM\fR .RS 4 Memory allocation failed\&. .RE .SH "NOTES" .PP These APIs are implemented as a shared library, which can be compiled and linked to with the \fBlibsystemd\fR\ \&\fBpkg-config\fR(1) file\&. .SH "SEE ALSO" .PP \fBsystemd\fR(1), \fBsd-bus\fR(3) \fBsd_bus_slot_ref\fR(3), \fBsd_bus_slot_set_userdata\fR(3)