]> git.ipfire.org Git - thirdparty/systemd.git/blob - man/sd_bus_message_append_strv.xml
e10b2f3ef7b865d9744e622595803dfb0dde8ae3
[thirdparty/systemd.git] / man / sd_bus_message_append_strv.xml
1 <?xml version='1.0'?> <!--*- Mode: nxml; nxml-child-indent: 2; indent-tabs-mode: nil -*-->
2 <!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
3 "http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
4
5 <!--
6 SPDX-License-Identifier: LGPL-2.1+
7 -->
8
9 <refentry id="sd_bus_message_append_strv"
10 xmlns:xi="http://www.w3.org/2001/XInclude">
11
12 <refentryinfo>
13 <title>sd_bus_message_append_strv</title>
14 <productname>systemd</productname>
15
16 <authorgroup>
17 <author>
18 <contrib>A monkey with a typewriter</contrib>
19 <firstname>Zbigniew</firstname>
20 <surname>Jędrzejewski-Szmek</surname>
21 <email>zbyszek@in.waw.pl</email>
22 </author>
23 </authorgroup>
24 </refentryinfo>
25
26 <refmeta>
27 <refentrytitle>sd_bus_message_append_strv</refentrytitle>
28 <manvolnum>3</manvolnum>
29 </refmeta>
30
31 <refnamediv>
32 <refname>sd_bus_message_append_strv</refname>
33
34 <refpurpose>Attach an array of strings to a message</refpurpose>
35 </refnamediv>
36
37 <refsynopsisdiv>
38 <funcsynopsis>
39 <funcsynopsisinfo>#include &lt;systemd/sd-bus.h&gt;</funcsynopsisinfo>
40
41 <funcprototype>
42 <funcdef>int sd_bus_message_append_strv</funcdef>
43 <paramdef>sd_bus_message *<parameter>m</parameter></paramdef>
44 <paramdef>char **<parameter>l</parameter></paramdef>
45 </funcprototype>
46 </funcsynopsis>
47 </refsynopsisdiv>
48
49 <refsect1>
50 <title>Description</title>
51
52 <para>The <function>sd_bus_message_append</function> function can be
53 used to append an array of strings to message
54 <parameter>m</parameter>. The parameter <parameter>l</parameter>
55 shall point to a <constant>NULL</constant>-terminated array of pointers
56 to <constant>NUL</constant>-terminated strings. Each string must
57 satisfy the same constraints as described for the
58 <literal>s</literal> type in
59 <citerefentry><refentrytitle>sd_bus_message_append_basic</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
60 </para>
61
62 <para>The memory pointed at by <parameter>p</parameter> and the
63 contents of the strings themselves are copied into the memory area
64 containing the message and may be changed after this call. Note
65 that the signature of <parameter>l</parameter> parameter is to be
66 treated as <type>const char *const *</type>, and the contents
67 will not be modified.</para>
68 </refsect1>
69
70 <refsect1>
71 <title>Return Value</title>
72
73 <para>On success, this call returns 0 or a positive integer. On
74 failure, a negative errno-style error code is returned.</para>
75 </refsect1>
76
77 <xi:include href="sd_bus_message_append_basic.xml" xpointer="errors" />
78
79 <xi:include href="libsystemd-pkgconfig.xml" />
80
81 <refsect1>
82 <title>See Also</title>
83
84 <para>
85 <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
86 <citerefentry><refentrytitle>sd-bus</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
87 <citerefentry><refentrytitle>sd_bus_message_append</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
88 <citerefentry><refentrytitle>sd_bus_message_append_array</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
89 <ulink url="http://dbus.freedesktop.org/doc/dbus-specification.html">The D-Bus specification</ulink>
90 </para>
91 </refsect1>
92
93 </refentry>