]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
nspawn: trivial improvements
authorLennart Poettering <lennart@poettering.net>
Wed, 13 Nov 2024 11:15:08 +0000 (12:15 +0100)
committerLennart Poettering <lennart@poettering.net>
Thu, 19 Dec 2024 14:33:34 +0000 (15:33 +0100)
src/nspawn/nspawn.c

index 8a07000fce3d6ef339c4624b3cac5809c369d343..f0753d18ae6e3a0d5449c2c5d3cf606e1649f9cf 100644 (file)
@@ -1251,7 +1251,7 @@ static int parse_argv(int argc, char *argv[]) {
                                 arg_uid_range = UINT32_C(0x10000);
 
                         } else if (streq(optarg, "identity")) {
-                                /* identity: User namespaces on, UID range is map the 0…0xFFFF range to
+                                /* identity: User namespaces on, UID range is map of the 0…0xFFFF range to
                                  * itself, i.e. we don't actually map anything, but do take benefit of
                                  * isolation of capability sets. */
                                 arg_userns_mode = USER_NAMESPACE_FIXED;
@@ -3255,6 +3255,7 @@ static int chase_and_update(char **p, unsigned flags) {
 }
 
 static int determine_uid_shift(const char *directory) {
+        assert(directory);
 
         if (arg_userns_mode == USER_NAMESPACE_NO) {
                 arg_uid_shift = 0;