]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
shells.c: call setusershell before getusershell
authorWanBingjiang <wanbingjiang@webray.com.cn>
Thu, 8 May 2025 02:28:48 +0000 (10:28 +0800)
committerKarel Zak <kzak@redhat.com>
Mon, 19 May 2025 09:33:47 +0000 (11:33 +0200)
lib/shells.c

index 18e4cca4abd06945b803005be2c90bf60f89bd39..adf7d8c1d3fa1ceb89d3c9e305248ea92be6cc17 100644 (file)
@@ -63,6 +63,7 @@ extern void print_shells(FILE *out, const char *format)
 #else
         char *s;
 
+               setusershell();
         while ((s = getusershell()))
                fprintf(out, format, s);
         endusershell();