summaryrefslogtreecommitdiffstats
path: root/debian/patches/542_useradd-O_option
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:46:56 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-15 20:46:56 +0000
commit2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b (patch)
tree96185c3fd8772392c9989835f1b9954b5aadb9d8 /debian/patches/542_useradd-O_option
parentAdding upstream version 1:4.13+dfsg1. (diff)
downloadshadow-2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b.tar.xz
shadow-2dd01f6cc0c6333b58c3e77f3d8a3dca116a1c8b.zip
Adding debian version 1:4.13+dfsg1-4.debian/1%4.13+dfsg1-4
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian/patches/542_useradd-O_option')
-rw-r--r--debian/patches/542_useradd-O_option40
1 files changed, 40 insertions, 0 deletions
diff --git a/debian/patches/542_useradd-O_option b/debian/patches/542_useradd-O_option
new file mode 100644
index 0000000..3745826
--- /dev/null
+++ b/debian/patches/542_useradd-O_option
@@ -0,0 +1,40 @@
+Goal: accepts the -O flag for backward compatibility. (was used by adduser?)
+
+Note: useradd.8 needs to be regenerated.
+
+Status wrt upstream: not included as this is just specific
+ backward compatibility for Debian
+
+--- a/man/useradd.8.xml
++++ b/man/useradd.8.xml
+@@ -326,6 +326,11 @@
+ =<replaceable>100</replaceable>&nbsp;<option>-K</option>&nbsp;
+ <replaceable>UID_MAX</replaceable>=<replaceable>499</replaceable>
+ </para>
++ <para>
++ For the compatibility with previous Debian's
++ <command>useradd</command>, the <option>-O</option> option is
++ also supported.
++ </para>
+ <!--para>
+ Note: <option>-K</option>&nbsp;<replaceable>UID_MIN</replaceable>=<replaceable>10</replaceable>,<replaceable>UID_MAX</replaceable>=<replaceable>499</replaceable>
+ doesn't work yet.
+--- a/src/useradd.c
++++ b/src/useradd.c
+@@ -1227,7 +1227,7 @@
+ {NULL, 0, NULL, '\0'}
+ };
+ while ((c = getopt_long (argc, argv,
+- "b:c:d:De:f:g:G:hk:K:lmMNop:rR:P:s:u:U"
++ "b:c:d:De:f:g:G:hk:O:K:lmMNop:rR:P:s:u:U"
+ #ifdef WITH_SELINUX
+ "Z:"
+ #endif /* WITH_SELINUX */
+@@ -1367,6 +1367,7 @@
+ kflg = true;
+ break;
+ case 'K':
++ case 'O': /* compatibility with previous Debian useradd */
+ /*
+ * override login.defs defaults (-K name=value)
+ * example: -K UID_MIN=100 -K UID_MAX=499