#include <sys/ioctl.h>
#include <sys/socket.h>
#include <sys/un.h>
-#include "macro.h"
#include "extension.h"
#include "message.h"
#include "admin.h"
while(*callp)
callp = &((*callp)->next);
- *callp = (struct chan_call *)MALLOC(sizeof(struct chan_call));
+ *callp = (struct chan_call *)malloc(sizeof(struct chan_call));
return(*callp);
}
adminp = &admin_first;
while(*adminp)
adminp = &((*adminp)->next);
- admin = (struct admin_list *)MALLOC(sizeof(struct admin_list));
+ admin = (struct admin_list *)malloc(sizeof(struct admin_list));
*adminp = admin;
admin->msg.type = message_type;
}
/* free head */
admin_first = admin->next;
- FREE(admin, 0);
+ free(admin);
work = 1;
} else
/* set socket address and name */
memset(&sock_address, 0, sizeof(sock_address));
sock_address.sun_family = PF_UNIX;
- UCPY(sock_address.sun_path, socket_name);
+ strcpy(sock_address.sun_path, socket_name);
/* connect socket */
if ((conn = connect(sock, (struct sockaddr *)&sock_address, SUN_LEN(&sock_address))) < 0)
/* enque hello message */
memset(¶m, 0, sizeof(param));
- SCPY(param.hello.application, "asterisk");
+ strcpy(param.hello.application, "asterisk");
send_message(MESSAGE_HELLO, 0, ¶m);
/* bchannel */