Commit e8230f27 authored by Cedric Roux's avatar Cedric Roux

- Bugfix for epoll_wait and interrupted system call when using gdb

- Fix memory leaks for itti_analyzer

git-svn-id: http://svn.eurecom.fr/openair4G/trunk@4333 818b1a75-f10b-46b9-bf7c-635c3b92a50f
parent dce1c3b0
...@@ -402,14 +402,16 @@ static inline void itti_receive_msg_internal_event_fd(task_id_t task_id, uint8_t ...@@ -402,14 +402,16 @@ static inline void itti_receive_msg_internal_event_fd(task_id_t task_id, uint8_t
epoll_timeout = -1; epoll_timeout = -1;
} }
epoll_ret = epoll_wait(itti_desc.tasks[thread_id].epoll_fd, do {
itti_desc.tasks[thread_id].events, epoll_ret = epoll_wait(itti_desc.tasks[thread_id].epoll_fd,
itti_desc.tasks[thread_id].nb_events, itti_desc.tasks[thread_id].events,
epoll_timeout); itti_desc.tasks[thread_id].nb_events,
epoll_timeout);
} while (epoll_ret < 0 && errno == EINTR);
if (epoll_ret < 0) { if (epoll_ret < 0) {
ITTI_ERROR("epoll_wait failed for task %s: %s\n", ITTI_ERROR("epoll_wait failed for task %s: %s\n",
itti_get_task_name(task_id), strerror(errno)); itti_get_task_name(task_id), strerror(errno));
DevAssert(0 == 1); DevAssert(0 == 1);
} }
if (epoll_ret == 0 && polling) { if (epoll_ret == 0 && polling) {
......
...@@ -101,7 +101,7 @@ int resolve_struct(types_t **head) ...@@ -101,7 +101,7 @@ int resolve_struct(types_t **head)
if (next_type->type != TYPE_STRUCT) if (next_type->type != TYPE_STRUCT)
continue; continue;
// printf("Trying to resolve struct members %s with type %d\n", next_type->name, next_type->id); // g_debug("Trying to resolve struct members %s with type %d", next_type->name, next_type->id);
/* Struct may have no member */ /* Struct may have no member */
if (next_type->members == NULL) if (next_type->members == NULL)
...@@ -135,7 +135,8 @@ int resolve_struct(types_t **head) ...@@ -135,7 +135,8 @@ int resolve_struct(types_t **head)
/* Pick up the next string available */ /* Pick up the next string available */
member = strtok(NULL, " _"); member = strtok(NULL, " _");
} }
// next_type->type_hr_display(next_type, 0);
free(members);
} }
return 0; return 0;
...@@ -185,7 +186,8 @@ int resolve_union(types_t **head) ...@@ -185,7 +186,8 @@ int resolve_union(types_t **head)
/* Pick up the next string available */ /* Pick up the next string available */
member = strtok(NULL, " _"); member = strtok(NULL, " _");
} }
// next_type->type_hr_display(next_type, 0);
free(members);
} }
return 0; return 0;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment