#include <asterisk/dsp.h>
#include <asterisk/logger.h>
#include <asterisk/options.h>
+#include <asterisk/utils.h>
#include "asterisk.h"
#include "astconf.h"
char *context;
int ret;
/* If no mailbox, return immediately */
- if (!strlen(mailbox))
+ if (ast_strlen_zero(mailbox))
return 0;
if (strchr(mailbox, ',')) {
strncpy(tmp, mailbox, sizeof(tmp));
mb = tmp;
ret = 0;
while((cur = strsep(&mb, ","))) {
- if (strlen(cur)) {
+ if (!ast_strlen_zero(cur)) {
if (ast_app_has_voicemail(cur))
return 1;
}
if (oldmsgs)
*oldmsgs = 0;
/* If no mailbox, return immediately */
- if (!strlen(mailbox))
+ if (ast_strlen_zero(mailbox))
return 0;
if (strchr(mailbox, ',')) {
int tmpnew, tmpold;
mb = tmp;
ret = 0;
while((cur = strsep(&mb, ", "))) {
- if (strlen(cur)) {
+ if (!ast_strlen_zero(cur)) {
if (ast_app_messagecount(cur, newmsgs ? &tmpnew : NULL, oldmsgs ? &tmpold : NULL))
return -1;
else {