summary refs log tree commit diff
path: root/src/core/systemd/nm-sd-utils-core.c
diff options
context:
space:
mode:
authorMichael Biebl <biebl@debian.org>2021-02-11 18:11:46 +0100
committerMichael Biebl <biebl@debian.org>2021-02-11 18:11:46 +0100
commit80ec1decc49c72efec2a8b87c06245c92c0ab807 (patch)
treee3b229aa94e8dcf0590f2317664176e7b8f7607b /src/core/systemd/nm-sd-utils-core.c
parent65f86e8f56267192d42f2b629fc6b0c99fb9cd0c (diff)
New upstream version 1.29.90 upstream/1.29.90
Diffstat (limited to 'src/core/systemd/nm-sd-utils-core.c')
-rw-r--r--src/core/systemd/nm-sd-utils-core.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/core/systemd/nm-sd-utils-core.c b/src/core/systemd/nm-sd-utils-core.c
new file mode 100644
index 00000000..af68603e
--- /dev/null
+++ b/src/core/systemd/nm-sd-utils-core.c
@@ -0,0 +1,27 @@
+/* SPDX-License-Identifier: LGPL-2.1-or-later */
+/*
+ * Copyright (C) 2018 Red Hat, Inc.
+ */
+
+#include "src/core/systemd/nm-default-systemd.h"
+
+#include "nm-sd-utils-core.h"
+
+#include "nm-core-internal.h"
+
+#include "nm-sd-adapt-core.h"
+
+#include "sd-id128.h"
+
+/*****************************************************************************/
+
+NMUuid *
+nm_sd_utils_id128_get_machine(NMUuid *out_uuid)
+{
+    g_assert(out_uuid);
+
+    G_STATIC_ASSERT_EXPR(sizeof(*out_uuid) == sizeof(sd_id128_t));
+    if (sd_id128_get_machine((sd_id128_t *) out_uuid) < 0)
+        return NULL;
+    return out_uuid;
+}