MSAPI_RETV_IF(client_sock == NULL, MS_MEDIA_ERR_INVALID_PARAMETER);
- client_addr_len = sizeof(client_addr);
+ client_addr_len = (socklen_t)sizeof(client_addr);
if ((sockfd = accept(serv_sock, (struct sockaddr*)&client_addr, &client_addr_len)) < 0) {
MSAPI_DBG_STRERROR("accept failed");
*client_sock = -1;
static gboolean __ms_dcm_agent_recv_msg_from_server(void)
{
struct sockaddr_un serv_addr;
- unsigned int serv_addr_len;
+ socklen_t serv_addr_len;
int sockfd = -1;
int retry = 10;
if (g_dcm_comm_sock <= 0)
__ms_dcm_agent_prepare_tcp_socket(&g_dcm_comm_sock, MS_DCM_COMM_PORT);
- serv_addr_len = sizeof(serv_addr);
+ serv_addr_len = (socklen_t)sizeof(serv_addr);
if ((sockfd = accept(g_dcm_comm_sock, (struct sockaddr*)&serv_addr, &serv_addr_len)) < 0) {
MS_DBG_STRERROR("accept failed");
static gboolean __ms_dcm_agent_read_socket(GIOChannel *src, GIOCondition condition, gpointer data)
{
struct sockaddr_un client_addr;
- unsigned int client_addr_len;
+ socklen_t client_addr_len;
dcmMsg *recv_msg = NULL;
dcmRequest *dcm_req = NULL;
int sock = -1;
sock = g_io_channel_unix_get_fd(src);
MS_DBG_RETVM_IF(sock < 0, G_SOURCE_CONTINUE, "sock fd is invalid!");
- client_addr_len = sizeof(client_addr);
+ client_addr_len = (socklen_t)sizeof(client_addr);
if ((client_sock = accept(sock, (struct sockaddr*)&client_addr, &client_addr_len)) < 0) {
MS_DBG_STRERROR("accept failed");