]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/core/emergency-action.h
tree-wide: use -EINVAL for enum invalid values
[thirdparty/systemd.git] / src / core / emergency-action.h
index 95d49a816620197c9d40923dc4e9ce18bb9a95c0..4d7e755ae1d25ecfcff5eacec9f10e6a675aedcb 100644 (file)
@@ -1,6 +1,8 @@
 /* SPDX-License-Identifier: LGPL-2.1-or-later */
 #pragma once
 
+#include <errno.h>
+
 typedef enum EmergencyAction {
         EMERGENCY_ACTION_NONE,
         EMERGENCY_ACTION_REBOOT,
@@ -13,7 +15,7 @@ typedef enum EmergencyAction {
         _EMERGENCY_ACTION_FIRST_USER_ACTION = EMERGENCY_ACTION_EXIT,
         EMERGENCY_ACTION_EXIT_FORCE,
         _EMERGENCY_ACTION_MAX,
-        _EMERGENCY_ACTION_INVALID = -1
+        _EMERGENCY_ACTION_INVALID = -EINVAL,
 } EmergencyAction;
 
 typedef enum EmergencyActionFlags {