static int append_mailbox(char *context, char *mbox, char *data)
{
/* Assumes lock is already held */
- char tmp[256] = "";
+ char *tmp;
char *stringp;
char *s;
struct ast_vm_user *vmu;
- ast_copy_string(tmp, data, sizeof(tmp));
+ tmp = ast_strdupa(data);
+
vmu = malloc(sizeof(struct ast_vm_user));
if (vmu) {
memset(vmu, 0, sizeof(struct ast_vm_user));
buf[strlen(buf)-1] = '\0';
consolehandler((char *)buf);
- } else {
+ } else if (option_remote) {
if (write(STDOUT_FILENO, "\nUse EXIT or QUIT to exit the asterisk console\n",
strlen("\nUse EXIT or QUIT to exit the asterisk console\n")) < 0) {
/* Whoa, stdout disappeared from under us... Make /dev/null's */
return RESULT_SUCCESS;
}
/*! \brief print_group: Print call group and pickup group ---*/
-static void print_group(int fd, unsigned int group, int crlf)
+static void print_group(int fd, ast_group_t group, int crlf)
{
char buf[256];
ast_cli(fd, crlf ? "%s\r\n" : "%s\n", ast_print_group(buf, sizeof(buf), group) );
/* A linked list for variables */
struct varshead varshead;
- unsigned int callgroup;
- unsigned int pickupgroup;
+ ast_group_t callgroup;
+ ast_group_t pickupgroup;
/*! channel flags of AST_FLAG_ type */
unsigned int flags;