projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Rename liblttsessiondcomm to liblttng-sessiond-comm, install it.
[lttng-tools.git]
/
liblttkconsumerd
/
liblttkconsumerd.c
diff --git
a/liblttkconsumerd/liblttkconsumerd.c
b/liblttkconsumerd/liblttkconsumerd.c
index f60888a83fc8f5ebc5758155770876973216c01e..9ad380c8dab5e8c1be679a0881890e929f355c57 100644
(file)
--- a/
liblttkconsumerd/liblttkconsumerd.c
+++ b/
liblttkconsumerd/liblttkconsumerd.c
@@
-177,6
+177,7
@@
static int kconsumerd_add_fd(struct lttcomm_kconsumerd_msg *buf, int consumerd_f
tmp_fd->state = buf->state;
tmp_fd->max_sb_size = buf->max_sb_size;
strncpy(tmp_fd->path_name, buf->path_name, PATH_MAX);
tmp_fd->state = buf->state;
tmp_fd->max_sb_size = buf->max_sb_size;
strncpy(tmp_fd->path_name, buf->path_name, PATH_MAX);
+ tmp_fd->path_name[PATH_MAX - 1] = '\0';
/* Opening the tracefile in write mode */
ret = open(tmp_fd->path_name,
/* Opening the tracefile in write mode */
ret = open(tmp_fd->path_name,
@@
-1004,7
+1005,7
@@
end:
*/
void kconsumerd_cleanup(void)
{
*/
void kconsumerd_cleanup(void)
{
- struct kconsumerd_fd *iter;
+ struct kconsumerd_fd *iter
, *tmp
;
/* remove the socket file */
unlink(kconsumerd_command_sock_path);
/* remove the socket file */
unlink(kconsumerd_command_sock_path);
@@
-1014,7
+1015,7
@@
void kconsumerd_cleanup(void)
* running (after joining on the threads), no need to protect
* list iteration with mutex.
*/
* running (after joining on the threads), no need to protect
* list iteration with mutex.
*/
- cds_list_for_each_entry
(iter
, &kconsumerd_data.fd_list.head, list) {
+ cds_list_for_each_entry
_safe(iter, tmp
, &kconsumerd_data.fd_list.head, list) {
kconsumerd_del_fd(iter);
}
}
kconsumerd_del_fd(iter);
}
}
This page took
0.024131 seconds
and
4
git commands to generate.