]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/libsystemd/sd-bus/bus-dump.c
Add SPDX license identifiers to source files under the LGPL
[thirdparty/systemd.git] / src / libsystemd / sd-bus / bus-dump.c
index 8833b9c677aa0de68b80d676b82d613df54658a8..2d93e1e43787186542b10e8c9472cb013e424b5e 100644 (file)
@@ -1,5 +1,4 @@
-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-
+/* SPDX-License-Identifier: LGPL-2.1+ */
 /***
   This file is part of systemd.
 
   along with systemd; If not, see <http://www.gnu.org/licenses/>.
 ***/
 
-#include "util.h"
-#include "capability.h"
-#include "strv.h"
-#include "macro.h"
-#include "cap-list.h"
-#include "formats-util.h"
-#include "terminal-util.h"
-
-#include "bus-message.h"
+#include "alloc-util.h"
+#include "bus-dump.h"
 #include "bus-internal.h"
+#include "bus-message.h"
 #include "bus-type.h"
-#include "bus-dump.h"
+#include "cap-list.h"
+#include "capability-util.h"
+#include "fileio.h"
+#include "format-util.h"
+#include "locale-util.h"
+#include "macro.h"
+#include "string-util.h"
+#include "strv.h"
+#include "terminal-util.h"
+#include "util.h"
 
 static char *indent(unsigned level, unsigned flags) {
         char *p;
@@ -73,7 +75,7 @@ int bus_message_dump(sd_bus_message *m, FILE *f, unsigned flags) {
                         "%s%s%s Type=%s%s%s  Endian=%c  Flags=%u  Version=%u  Priority=%"PRIi64,
                         m->header->type == SD_BUS_MESSAGE_METHOD_ERROR ? ansi_highlight_red() :
                         m->header->type == SD_BUS_MESSAGE_METHOD_RETURN ? ansi_highlight_green() :
-                        m->header->type != SD_BUS_MESSAGE_SIGNAL ? ansi_highlight() : "", draw_special_char(DRAW_TRIANGULAR_BULLET), ansi_normal(),
+                        m->header->type != SD_BUS_MESSAGE_SIGNAL ? ansi_highlight() : "", special_glyph(TRIANGULAR_BULLET), ansi_normal(),
                         ansi_highlight(), bus_message_type_to_string(m->header->type), ansi_normal(),
                         m->header->endian,
                         m->header->flags,
@@ -197,7 +199,7 @@ int bus_message_dump(sd_bus_message *m, FILE *f, unsigned flags) {
                         else if (type == SD_BUS_TYPE_DICT_ENTRY)
                                 fprintf(f, "%sDICT_ENTRY \"%s\" {\n", prefix, contents);
 
-                        level ++;
+                        level++;
 
                         continue;
                 }