usage.h: fix compile-time bugs exposed by previous change

This commit is contained in:
Denis Vlasenko 2006-09-27 23:31:59 +00:00
parent ce97960a6e
commit de9ec92958
2 changed files with 8 additions and 11 deletions

View File

@ -412,17 +412,17 @@ USE_FEATURE_DATE_ISOFMT( \
#define deallocvt_trivial_usage \ #define deallocvt_trivial_usage \
"[N]" "[N]"
#define deallocvt_full_usage \ #define deallocvt_full_usage \
"Deallocate unused virtual terminal /dev/ttyN" "Deallocate unused virtual terminal /dev/ttyN"
#define delgroup_trivial_usage \ #define delgroup_trivial_usage \
"GROUP" "GROUP"
#define delgroup_full_usage \ #define delgroup_full_usage \
"Deletes group GROUP from the system" "Deletes group GROUP from the system"
#define deluser_trivial_usage \ #define deluser_trivial_usage \
"USER" "USER"
#define deluser_full_usage \ #define deluser_full_usage \
"Deletes user USER from the system" "Deletes user USER from the system"
#define devfsd_trivial_usage \ #define devfsd_trivial_usage \
"mntpnt [-v]" \ "mntpnt [-v]" \
@ -2146,8 +2146,7 @@ USE_FEATURE_MDEV_CONFIG( \
"changes the password for the current user.\n" \ "changes the password for the current user.\n" \
"Options:\n" \ "Options:\n" \
"\t-a\tDefine which algorithm shall be used for the password\n" \ "\t-a\tDefine which algorithm shall be used for the password\n" \
"\t\t\t(Choices: des, md5" \ "\t\t\t(Choices: des, md5, sha1)\n" \
USE_FEATURE_SHA1_PASSWORDS(", sha1") ")\n" \
"\t-d\tDelete the password for the specified user account\n" \ "\t-d\tDelete the password for the specified user account\n" \
"\t-l\tLocks (disables) the specified user account\n" \ "\t-l\tLocks (disables) the specified user account\n" \
"\t-u\tUnlocks (re-enables) the specified user account" "\t-u\tUnlocks (re-enables) the specified user account"
@ -2408,9 +2407,9 @@ USE_FEATURE_MDEV_CONFIG( \
#define route_full_usage \ #define route_full_usage \
"Edit the kernel's routing tables.\n\n" \ "Edit the kernel's routing tables.\n\n" \
"Options:\n" \ "Options:\n" \
"\t-n\t\tDont resolve names\n" \ "\t-n\tDont resolve names\n" \
"\t-e\t\tDisplay other/more information\n" \ "\t-e\tDisplay other/more information\n" \
"\t-A inet" USE_FEATURE_ROUTE_IPV6("{6}") "\tSelect address family" "\t-A inet" USE_FEATURE_IPV6("{6}") "\tSelect address family"
#define rpm_trivial_usage \ #define rpm_trivial_usage \
"-i -q[ildc]p package.rpm" "-i -q[ildc]p package.rpm"

View File

@ -11,13 +11,12 @@
#include <string.h> #include <string.h>
#include <crypt.h> #include <crypt.h>
char *pw_encrypt(const char *clear, const char *salt) char *pw_encrypt(const char *clear, const char *salt)
{ {
static char cipher[128]; static char cipher[128];
char *cp; char *cp;
#ifdef CONFIG_FEATURE_SHA1_PASSWORDS #if 0 /* was CONFIG_FEATURE_SHA1_PASSWORDS, but there is no such thing??? */
if (strncmp(salt, "$2$", 3) == 0) { if (strncmp(salt, "$2$", 3) == 0) {
return sha1_crypt(clear); return sha1_crypt(clear);
} }
@ -29,4 +28,3 @@ char *pw_encrypt(const char *clear, const char *salt)
safe_strncpy(cipher, cp, sizeof(cipher)); safe_strncpy(cipher, cp, sizeof(cipher));
return cipher; return cipher;
} }