convert a few more uses of strlen where ast_strlen_zero should be used

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@13622 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Russell Bryant 19 years ago
parent 222afff88a
commit dfb45b71df

10
db.c

@ -520,15 +520,15 @@ static int manager_dbput(struct mansession *s, struct message *m)
char *val = astman_get_header(m, "Val"); char *val = astman_get_header(m, "Val");
int res; int res;
if (!strlen(family)) { if (ast_strlen_zero(family)) {
astman_send_error(s, m, "No family specified"); astman_send_error(s, m, "No family specified");
return 0; return 0;
} }
if (!strlen(key)) { if (ast_strlen_zero(key)) {
astman_send_error(s, m, "No key specified"); astman_send_error(s, m, "No key specified");
return 0; return 0;
} }
if (!strlen(val)) { if (ast_strlen_zero(val)) {
astman_send_error(s, m, "No val specified"); astman_send_error(s, m, "No val specified");
return 0; return 0;
} }
@ -551,11 +551,11 @@ static int manager_dbget(struct mansession *s, struct message *m)
char tmp[256]; char tmp[256];
int res; int res;
if (!strlen(family)) { if (ast_strlen_zero(family)) {
astman_send_error(s, m, "No family specified."); astman_send_error(s, m, "No family specified.");
return 0; return 0;
} }
if (!strlen(key)) { if (ast_strlen_zero(key)) {
astman_send_error(s, m, "No key specified."); astman_send_error(s, m, "No key specified.");
return 0; return 0;
} }

Loading…
Cancel
Save