[systemd-commits] 3 commits - .mailmap Makefile-man.am man/sd_bus_creds_get_pid.xml man/sd_bus_creds_new_from_pid.xml man/sd_bus_new.xml src/core src/libsystemd-bus src/systemd

Zbigniew Jędrzejewski-Szmek zbyszek at kemper.freedesktop.org
Sat Jan 4 21:44:50 PST 2014


 .mailmap                          |    4 
 Makefile-man.am                   |   17 ++
 man/sd_bus_creds_get_pid.xml      |    8 +
 man/sd_bus_creds_new_from_pid.xml |  275 ++++++++++++++++++++++++++++++++++++++
 man/sd_bus_new.xml                |    2 
 src/core/swap.c                   |    5 
 src/libsystemd-bus/bus-creds.c    |    2 
 src/systemd/sd-bus.h              |    2 
 8 files changed, 307 insertions(+), 8 deletions(-)

New commits:
commit 9dddaedfcc70c6dc37ba6a48d1d8e27e12c0cb2e
Author: Stefan Beller <stefanbeller at googlemail.com>
Date:   Fri Jan 3 20:33:21 2014 +0100

    Update .mailmap file
    
    This commit updates email addresses of people, who are already in the
    .mailmap file, so I'd assume they have sorted out their viewpoint on
    privacy within the .mailmap file.
    
    The entries for this commit have been produced using:
            # Finding out duplicates by comparing email addresses:
            git shortlog -sne |awk '{ print $NF }' |sort |uniq -d
    
            # Finding out duplicates by comparing names:
            git shortlog -sne |awk '{ NF--; $1=""; print }' |sort |uniq -d

diff --git a/.mailmap b/.mailmap
index ddaf4d5..e1cdf06 100644
--- a/.mailmap
+++ b/.mailmap
@@ -3,6 +3,7 @@ Kay Sievers <kay at vrfy.org> <kay.sievers at vrfy.org>
 Kay Sievers <kay at vrfy.org> <kay.sievers at suse.de>
 Kay Sievers <kay at vrfy.org> <kay at pim.off.vrfy.org>
 Kay Sievers <kay at vrfy.org> <kay at pim>
+Kay Sievers <kay at vrfy.org> <kay at yik.fritz.box>
 Greg KH <greg at kroah.com>
 Greg KH <greg at kroah.com> <greg at kroah.com>
 Greg KH <greg at kroah.com> <greg at press.(none)>
@@ -36,7 +37,7 @@ Michal Soltys <soltys at ziu.info> <nozo at ziu.info>
 Piter PUNK <piterpunk at slackware.com> <piterpk at terra.com.br>
 Richard Hughes <richard at hughsie.com> <hughsient at gmail.com>
 Robby Workman <rw at rlworkman.net> <rworkman at slackware.com>
-Shawn Landden <shawnlandden at gmail.com>
+Shawn Landden <shawnlandden at gmail.com> <shawn at churchofgit.com>
 Simon Peeters <peeters.simon at gmail.com>
 Tobias Klauser <tklauser at distanz.ch> <tklauser at nuerscht.ch>
 Miklos Vajna <vmiklos at frugalware.org> <vmiklos at gmail.com>
@@ -50,6 +51,7 @@ Ted Ts'o <tytso at mit.edu>
 Tobias Klauser <tklauser at access.unizh.ch>
 Tobias Klauser <tklauser at access.unizh.ch> <tklauser at access.unizh.chbk>
 Tobias Klauser <tklauser at access.unizh.ch> <klauser at access.unizh.ch>
+Tobias Klauser <tklauser at access.unizh.ch> <tklauser at distanz.ch>
 Patrick Mansfield <patmans at us.ibm.com>
 Christophe Varoqui <christophe.varoqui at free.fr>
 Daniel Stekloff <dsteklof at us.ibm.com>

commit 7bb01eff62aa7b612e33fe0e512a4d97862050c4
Author: Stefan Beller <stefanbeller at googlemail.com>
Date:   Fri Jan 3 20:33:20 2014 +0100

    swap: remove if/else with the same data path
    
    This was introduced in e1770af812 (2012-02-03, swap: replace failure
    boolean by result enum).
    
    This just removes unneeded lines of code, no functional change.

diff --git a/src/core/swap.c b/src/core/swap.c
index e0627db..6b204df 100644
--- a/src/core/swap.c
+++ b/src/core/swap.c
@@ -999,10 +999,7 @@ static void swap_sigchld_event(Unit *u, pid_t pid, int code, int status) {
         case SWAP_DEACTIVATING_SIGKILL:
         case SWAP_DEACTIVATING_SIGTERM:
 
-                if (f == SWAP_SUCCESS)
-                        swap_enter_dead(s, f);
-                else
-                        swap_enter_dead(s, f);
+                swap_enter_dead(s, f);
                 break;
 
         default:

commit 4cf8496d0a5e85ec7610d166c5d35df3e6d02d1a
Author: Zbigniew Jędrzejewski-Szmek <zbyszek at in.waw.pl>
Date:   Sat Jan 4 19:28:52 2014 -0500

    man: document some more bus functions

diff --git a/Makefile-man.am b/Makefile-man.am
index 35174cc..75cccc0 100644
--- a/Makefile-man.am
+++ b/Makefile-man.am
@@ -21,6 +21,7 @@ MANPAGES += \
 	man/sd-journal.3 \
 	man/sd_booted.3 \
 	man/sd_bus_creds_get_pid.3 \
+	man/sd_bus_creds_new_from_pid.3 \
 	man/sd_bus_message_get_cookie.3 \
 	man/sd_bus_new.3 \
 	man/sd_bus_open_user.3 \
@@ -145,6 +146,7 @@ MANPAGES_ALIAS += \
 	man/sd_bus_creds_get_comm.3 \
 	man/sd_bus_creds_get_exe.3 \
 	man/sd_bus_creds_get_gid.3 \
+	man/sd_bus_creds_get_mask.3 \
 	man/sd_bus_creds_get_owner_uid.3 \
 	man/sd_bus_creds_get_pid_starttime.3 \
 	man/sd_bus_creds_get_selinux_context.3 \
@@ -161,6 +163,8 @@ MANPAGES_ALIAS += \
 	man/sd_bus_creds_has_effective_cap.3 \
 	man/sd_bus_creds_has_inheritable_cap.3 \
 	man/sd_bus_creds_has_permitted_cap.3 \
+	man/sd_bus_creds_ref.3 \
+	man/sd_bus_creds_unref.3 \
 	man/sd_bus_default_system.3 \
 	man/sd_bus_default_user.3 \
 	man/sd_bus_message_get_reply_cookie.3 \
@@ -279,6 +283,7 @@ man/sd_bus_creds_get_cmdline.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_get_comm.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_get_exe.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_get_gid.3: man/sd_bus_creds_get_pid.3
+man/sd_bus_creds_get_mask.3: man/sd_bus_creds_new_from_pid.3
 man/sd_bus_creds_get_owner_uid.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_get_pid_starttime.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_get_selinux_context.3: man/sd_bus_creds_get_pid.3
@@ -295,6 +300,8 @@ man/sd_bus_creds_has_bounding_cap.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_has_effective_cap.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_has_inheritable_cap.3: man/sd_bus_creds_get_pid.3
 man/sd_bus_creds_has_permitted_cap.3: man/sd_bus_creds_get_pid.3
+man/sd_bus_creds_ref.3: man/sd_bus_creds_new_from_pid.3
+man/sd_bus_creds_unref.3: man/sd_bus_creds_new_from_pid.3
 man/sd_bus_default_system.3: man/sd_bus_open_user.3
 man/sd_bus_default_user.3: man/sd_bus_open_user.3
 man/sd_bus_message_get_reply_cookie.3: man/sd_bus_message_get_cookie.3
@@ -483,6 +490,9 @@ man/sd_bus_creds_get_exe.html: man/sd_bus_creds_get_pid.html
 man/sd_bus_creds_get_gid.html: man/sd_bus_creds_get_pid.html
 	$(html-alias)
 
+man/sd_bus_creds_get_mask.html: man/sd_bus_creds_new_from_pid.html
+	$(html-alias)
+
 man/sd_bus_creds_get_owner_uid.html: man/sd_bus_creds_get_pid.html
 	$(html-alias)
 
@@ -531,6 +541,12 @@ man/sd_bus_creds_has_inheritable_cap.html: man/sd_bus_creds_get_pid.html
 man/sd_bus_creds_has_permitted_cap.html: man/sd_bus_creds_get_pid.html
 	$(html-alias)
 
+man/sd_bus_creds_ref.html: man/sd_bus_creds_new_from_pid.html
+	$(html-alias)
+
+man/sd_bus_creds_unref.html: man/sd_bus_creds_new_from_pid.html
+	$(html-alias)
+
 man/sd_bus_default_system.html: man/sd_bus_open_user.html
 	$(html-alias)
 
@@ -1266,6 +1282,7 @@ EXTRA_DIST += \
 	man/sd-readahead.xml \
 	man/sd_booted.xml \
 	man/sd_bus_creds_get_pid.xml \
+	man/sd_bus_creds_new_from_pid.xml \
 	man/sd_bus_message_get_cookie.xml \
 	man/sd_bus_new.xml \
 	man/sd_bus_open_user.xml \
diff --git a/man/sd_bus_creds_get_pid.xml b/man/sd_bus_creds_get_pid.xml
index 9de5001..d059827 100644
--- a/man/sd_bus_creds_get_pid.xml
+++ b/man/sd_bus_creds_get_pid.xml
@@ -403,6 +403,14 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
       </varlistentry>
 
       <varlistentry>
+        <term><varname>-ENXIO</varname></term>
+
+        <listitem><para>An error occured in parsing cgroup paths.
+        <filename>libsystemd-bus</filename> might be out of sync with
+        the running systemd version.</para></listitem>
+      </varlistentry>
+
+      <varlistentry>
         <term><varname>-EINVAL</varname></term>
 
         <listitem><para>Specified pointer parameter is <constant>NULL</constant>.
diff --git a/man/sd_bus_creds_new_from_pid.xml b/man/sd_bus_creds_new_from_pid.xml
new file mode 100644
index 0000000..302004d
--- /dev/null
+++ b/man/sd_bus_creds_new_from_pid.xml
@@ -0,0 +1,275 @@
+<?xml version='1.0'?> <!--*-nxml-*-->
+<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.2//EN"
+"http://www.oasis-open.org/docbook/xml/4.2/docbookx.dtd">
+
+<!--
+This file is part of systemd.
+
+Copyright 2014 Zbigniew Jędrzejewski-Szmek
+
+systemd is free software; you can redistribute it and/or modify it
+under the terms of the GNU Lesser General Public License as published by
+the Free Software Foundation; either version 2.1 of the License, or
+(at your option) any later version.
+
+systemd is distributed in the hope that it will be useful, but
+WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public License
+along with systemd; If not, see <http://www.gnu.org/licenses/>.
+-->
+
+<refentry id="sd_bus_creds_new_from_pid">
+
+  <refentryinfo>
+    <title>sd_bus_creds_new_from_pid</title>
+    <productname>systemd</productname>
+
+    <authorgroup>
+      <author>
+        <contrib>A monkey with a typewriter</contrib>
+        <firstname>Zbigniew</firstname>
+        <surname>Jędrzejewski-Szmek</surname>
+        <email>zbyszek at in.waw.pl</email>
+      </author>
+    </authorgroup>
+  </refentryinfo>
+
+  <refmeta>
+    <refentrytitle>sd_bus_creds_new_from_pid</refentrytitle>
+    <manvolnum>3</manvolnum>
+  </refmeta>
+
+  <refnamediv>
+    <refname>sd_bus_creds_new_from_pid</refname>
+    <refname>sd_bus_creds_get_mask</refname>
+    <refname>sd_bus_creds_ref</refname>
+    <refname>sd_bus_creds_unref</refname>
+
+    <refpurpose>Retrieve credentials object for the specified PID</refpurpose>
+  </refnamediv>
+
+  <refsynopsisdiv>
+    <funcsynopsis>
+      <funcsynopsisinfo>#include <systemd/sd-bus.h></funcsynopsisinfo>
+
+      <funcprototype>
+        <funcdef>int <function>sd_bus_creds_new_from_pid</function></funcdef>
+        <paramdef>pid_t <parameter>pid</parameter></paramdef>
+        <paramdef>uint64_t <parameter>creds_mask</parameter></paramdef>
+        <paramdef>sd_bus_creds** <parameter>ret</parameter></paramdef>
+      </funcprototype>
+
+      <funcprototype>
+        <funcdef>uint64_t <function>sd_bus_creds_get_mask</function></funcdef>
+        <paramdef>const sd_bus_creds* <parameter>c</parameter></paramdef>
+      </funcprototype>
+
+      <funcprototype>
+        <funcdef>sd_bus_creds* <function>sd_bus_creds_ref</function></funcdef>
+        <paramdef>sd_bus_creds* <parameter>c</parameter></paramdef>
+      </funcprototype>
+
+      <funcprototype>
+        <funcdef>sd_bus_creds* <function>sd_bus_creds_unref</function></funcdef>
+        <paramdef>sd_bus_creds* <parameter>c</parameter></paramdef>
+      </funcprototype>
+    </funcsynopsis>
+
+    <para>
+      <constant>SD_BUS_CREDS_PID</constant>,
+      <constant>SD_BUS_CREDS_PID_STARTTIME</constant>,
+      <constant>SD_BUS_CREDS_TID</constant>,
+      <constant>SD_BUS_CREDS_UID</constant>,
+      <constant>SD_BUS_CREDS_GID</constant>,
+      <constant>SD_BUS_CREDS_COMM</constant>,
+      <constant>SD_BUS_CREDS_TID_COMM</constant>,
+      <constant>SD_BUS_CREDS_EXE</constant>,
+      <constant>SD_BUS_CREDS_CMDLINE</constant>,
+      <constant>SD_BUS_CREDS_CGROUP</constant>,
+      <constant>SD_BUS_CREDS_UNIT</constant>,
+      <constant>SD_BUS_CREDS_USER_UNIT</constant>,
+      <constant>SD_BUS_CREDS_SLICE</constant>,
+      <constant>SD_BUS_CREDS_SESSION</constant>,
+      <constant>SD_BUS_CREDS_OWNER_UID</constant>,
+      <constant>SD_BUS_CREDS_EFFECTIVE_CAPS</constant>,
+      <constant>SD_BUS_CREDS_PERMITTED_CAPS</constant>,
+      <constant>SD_BUS_CREDS_INHERITABLE_CAPS</constant>,
+      <constant>SD_BUS_CREDS_BOUNDING_CAPS</constant>,
+      <constant>SD_BUS_CREDS_SELINUX_CONTEXT</constant>,
+      <constant>SD_BUS_CREDS_AUDIT_SESSION_ID</constant>,
+      <constant>SD_BUS_CREDS_AUDIT_LOGIN_UID</constant>,
+      <constant>SD_BUS_CREDS_UNIQUE_NAME</constant>,
+      <constant>SD_BUS_CREDS_WELL_KNOWN_NAMES</constant>,
+      <constant>_SD_BUS_CREDS_ALL</constant>
+    </para>
+  </refsynopsisdiv>
+
+  <refsect1>
+    <title>Description</title>
+
+    <para><function>sd_bus_creds_new_from_pid()</function> creates a new
+    credentials object and fills it with information about the process
+    <parameter>pid</parameter>. This pointer to this object will
+    be stored in <parameter>ret</parameter> pointer.</para>
+
+    <para>The information that will be stored is determined by
+    <parameter>creds_mask</parameter>. It may contain a subset of ORed
+    constants <constant>SD_BUS_CREDS_PID</constant>,
+    <constant>SD_BUS_CREDS_PID_STARTTIME</constant>,
+    <constant>SD_BUS_CREDS_TID</constant>,
+    <constant>SD_BUS_CREDS_UID</constant>,
+    <constant>SD_BUS_CREDS_GID</constant>,
+    <constant>SD_BUS_CREDS_COMM</constant>,
+    <constant>SD_BUS_CREDS_TID_COMM</constant>,
+    <constant>SD_BUS_CREDS_EXE</constant>,
+    <constant>SD_BUS_CREDS_CMDLINE</constant>,
+    <constant>SD_BUS_CREDS_CGROUP</constant>,
+    <constant>SD_BUS_CREDS_UNIT</constant>,
+    <constant>SD_BUS_CREDS_USER_UNIT</constant>,
+    <constant>SD_BUS_CREDS_SLICE</constant>,
+    <constant>SD_BUS_CREDS_SESSION</constant>,
+    <constant>SD_BUS_CREDS_OWNER_UID</constant>,
+    <constant>SD_BUS_CREDS_EFFECTIVE_CAPS</constant>,
+    <constant>SD_BUS_CREDS_PERMITTED_CAPS</constant>,
+    <constant>SD_BUS_CREDS_INHERITABLE_CAPS</constant>,
+    <constant>SD_BUS_CREDS_BOUNDING_CAPS</constant>,
+    <constant>SD_BUS_CREDS_SELINUX_CONTEXT</constant>,
+    <constant>SD_BUS_CREDS_AUDIT_SESSION_ID</constant>,
+    <constant>SD_BUS_CREDS_AUDIT_LOGIN_UID</constant>,
+    <constant>SD_BUS_CREDS_UNIQUE_NAME</constant>,
+    <constant>SD_BUS_CREDS_WELL_KNOWN_NAMES</constant>,
+    or <constant>_SD_BUS_CREDS_ALL</constant> to indicate
+    all known fields.</para>
+
+    <para>Fields can be retrieved from the credentials object using
+    <citerefentry><refentrytitle>sd_bus_creds_get_pid</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+    and other functions which correspond directly to the constants
+    listed above.</para>
+
+    <para>A mask of fields which were actually sucessfully set
+    (acquired from <filename>/proc</filename>, etc.) can be retrieved
+    with <function>sd_bus_creds_get_mask()</function>. If the
+    credentials object was created with
+    <function>sd_bus_creds_new_from_pid()</function>, this will be a
+    subset of fields requested in <parameter>creds_mask</parameter>.
+    </para>
+
+    <para><function>sd_bus_creds_ref</function> creates a new
+    reference to the credentials object <parameter>c</parameter>. This
+    object will not be destroyed until
+    <function>sd_bus_creds_unref</function> has been called as many
+    times plus once more. Once the reference count has dropped to zero,
+    <parameter>c</parameter> cannot be used anymore, so futher
+    calls to <function>sd_bus_creds_ref(c)</function> or
+    <function>sd_bus_creds_unref(c)</function> are illegal.</para>
+
+    <para><function>sd_bus_creds_unref</function> destroys a reference
+    to <parameter>c</parameter>.</para>
+  </refsect1>
+
+  <refsect1>
+    <title>Return Value</title>
+
+    <para>On success, <function>sd_bus_creds_new_from_pid()</function>
+    returns 0 or a positive integer. On failure, it returns a negative
+    errno-style error code.</para>
+
+    <para><function>sd_bus_creds_get_mask()</function> returns the
+    mask of successfully acquired fields.</para>
+
+    <para><function>sd_bus_creds_ref</function> always returns the
+    argument.</para>
+
+    <para><function>sd_bus_creds_unref</function> always returns
+    <constant>NULL</constant>.</para>
+  </refsect1>
+
+  <refsect1>
+    <title>Reference ownership</title>
+
+    <para>Function <function>sd_bus_creds_new_from_pid()</function>
+    creates a new object and the caller owns the sole reference. When
+    not needed anymore, this reference should be destroyed with
+    <citerefentry><refentrytitle>sd_bus_creds_unref</refentrytitle><manvolnum>3</manvolnum></citerefentry>.
+    </para>
+  </refsect1>
+
+  <refsect1>
+    <title>Errors</title>
+
+    <para>Returned errors may indicate the following problems:</para>
+
+    <variablelist>
+
+      <varlistentry>
+        <term><varname>-ESRCH</varname></term>
+
+        <listitem><para>Specified <parameter>pid</parameter> could not
+        be found.</para></listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term><varname>-EINVAL</varname></term>
+
+        <listitem><para>Specified parameter is invalid
+        (<constant>NULL</constant> in case of output
+        parameters).</para></listitem>
+      </varlistentry>
+
+      <varlistentry>
+        <term><varname>-ENOMEM</varname></term>
+
+        <listitem><para>Memory allocation failed.</para></listitem>
+      </varlistentry>
+    </variablelist>
+  </refsect1>
+
+  <refsect1>
+    <title>Notes</title>
+
+    <para><function>sd_bus_creds_new_from_pid()</function> is
+    available as a shared library, which can be compiled and linked to
+    with the
+    <constant>libsystemd-bus</constant> <citerefentry><refentrytitle>pkg-config</refentrytitle><manvolnum>1</manvolnum></citerefentry>
+    file.</para>
+  </refsect1>
+
+  <refsect1>
+    <title>See Also</title>
+
+    <para>
+      <citerefentry><refentrytitle>systemd</refentrytitle><manvolnum>1</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd-bus</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_ref</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_unref</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_pid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_pid_starttime</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_tid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_uid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_gid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_comm</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_tid_comm</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_exe</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_cmdline</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_cgroup</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_unit</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_user_unit</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_slice</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_session</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_owner_uid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_has_effective_cap</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_has_permitted_cap</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_has_inheritable_cap</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_has_bounding_cap</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_selinux_context</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_audit_session_id</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_audit_login_uid</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_unique_name</refentrytitle><manvolnum>3</manvolnum></citerefentry>,
+      <citerefentry><refentrytitle>sd_bus_creds_get_well_known_names</refentrytitle><manvolnum>3</manvolnum></citerefentry>
+    </para>
+  </refsect1>
+
+</refentry>
diff --git a/man/sd_bus_new.xml b/man/sd_bus_new.xml
index 1931424..ad1e700 100644
--- a/man/sd_bus_new.xml
+++ b/man/sd_bus_new.xml
@@ -87,7 +87,7 @@ along with systemd; If not, see <http://www.gnu.org/licenses/>.
     further calls to <function>sd_bus_ref()</function> or
     <function>sd_bus_unref()</function> are illegal.</para>
 
-    <para><function>sd_bus_unref()</function> destroyes a reference to
+    <para><function>sd_bus_unref()</function> destroys a reference to
     <parameter>bus</parameter>.</para>
   </refsect1>
 
diff --git a/src/libsystemd-bus/bus-creds.c b/src/libsystemd-bus/bus-creds.c
index 5575f73..52e55fc 100644
--- a/src/libsystemd-bus/bus-creds.c
+++ b/src/libsystemd-bus/bus-creds.c
@@ -105,7 +105,7 @@ _public_ sd_bus_creds *sd_bus_creds_unref(sd_bus_creds *c) {
         return NULL;
 }
 
-_public_ uint64_t sd_bus_creds_get_mask(sd_bus_creds *c) {
+_public_ uint64_t sd_bus_creds_get_mask(const sd_bus_creds *c) {
         assert_return(c, 0);
 
         return c->mask;
diff --git a/src/systemd/sd-bus.h b/src/systemd/sd-bus.h
index 1134b58..a6c29d4 100644
--- a/src/systemd/sd-bus.h
+++ b/src/systemd/sd-bus.h
@@ -279,7 +279,7 @@ int sd_bus_query_sender_creds(sd_bus_message *call, uint64_t mask, sd_bus_creds
 int sd_bus_creds_new_from_pid(pid_t pid, uint64_t creds_mask, sd_bus_creds **ret);
 sd_bus_creds *sd_bus_creds_ref(sd_bus_creds *c);
 sd_bus_creds *sd_bus_creds_unref(sd_bus_creds *c);
-uint64_t sd_bus_creds_get_mask(sd_bus_creds *c);
+uint64_t sd_bus_creds_get_mask(const sd_bus_creds *c);
 
 int sd_bus_creds_get_pid(sd_bus_creds *c, pid_t *pid);
 int sd_bus_creds_get_pid_starttime(sd_bus_creds *c, uint64_t *usec);



More information about the systemd-commits mailing list