swapoff: dont pass "p" in opt_complementary

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
1_20_stable
Denys Vlasenko 2011-08-13 23:36:36 +02:00
parent c97578de6b
commit c21c310e46
1 changed files with 2 additions and 1 deletions

View File

@ -114,7 +114,8 @@ int swap_on_off_main(int argc UNUSED_PARAM, char **argv)
#if !ENABLE_FEATURE_SWAPON_PRI
ret = getopt32(argv, "a");
#else
opt_complementary = "p+";
if (applet_name[5] == 'n')
opt_complementary = "p+";
ret = getopt32(argv, (applet_name[5] == 'n') ? "ap:" : "a", &g_flags);
if (ret & 2) { // -p