projects
/
lttng-tools.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Remove calibrate from lttng-sessiond
[lttng-tools.git]
/
src
/
bin
/
lttng-sessiond
/
ust-consumer.c
diff --git
a/src/bin/lttng-sessiond/ust-consumer.c
b/src/bin/lttng-sessiond/ust-consumer.c
index ba464d9b7d90c8b1a318c527eefaf7f5032b2b02..3bb54f03983178f035fdcb345f8e1d7670557847 100644
(file)
--- a/
src/bin/lttng-sessiond/ust-consumer.c
+++ b/
src/bin/lttng-sessiond/ust-consumer.c
@@
-15,7
+15,6
@@
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
*/
-#define _GNU_SOURCE
#define _LGPL_SOURCE
#include <errno.h>
#include <stdio.h>
#define _LGPL_SOURCE
#include <errno.h>
#include <stdio.h>
@@
-25,7
+24,7
@@
#include <inttypes.h>
#include <common/common.h>
#include <inttypes.h>
#include <common/common.h>
-#include <common/consumer.h>
+#include <common/consumer
/consumer
.h>
#include <common/defaults.h>
#include "consumer.h"
#include <common/defaults.h>
#include "consumer.h"
@@
-73,7
+72,7
@@
static char *setup_trace_path(struct consumer_output *consumer,
ret = run_as_mkdir_recursive(pathname, S_IRWXU | S_IRWXG,
ua_sess->euid, ua_sess->egid);
if (ret < 0) {
ret = run_as_mkdir_recursive(pathname, S_IRWXU | S_IRWXG,
ua_sess->euid, ua_sess->egid);
if (ret < 0) {
- if (
ret != -
EEXIST) {
+ if (
errno !=
EEXIST) {
ERR("Trace directory creation error");
goto error;
}
ERR("Trace directory creation error");
goto error;
}
@@
-400,7
+399,9
@@
int ust_consumer_send_stream_to_ust(struct ust_app *app,
DBG2("UST consumer send stream to app %d", app->sock);
/* Relay stream to application. */
DBG2("UST consumer send stream to app %d", app->sock);
/* Relay stream to application. */
+ pthread_mutex_lock(&app->sock_lock);
ret = ustctl_send_stream_to_ust(app->sock, channel->obj, stream->obj);
ret = ustctl_send_stream_to_ust(app->sock, channel->obj, stream->obj);
+ pthread_mutex_unlock(&app->sock_lock);
if (ret < 0) {
if (ret != -EPIPE && ret != -LTTNG_UST_ERR_EXITING) {
ERR("ustctl send stream handle %d to app pid: %d with ret %d",
if (ret < 0) {
if (ret != -EPIPE && ret != -LTTNG_UST_ERR_EXITING) {
ERR("ustctl send stream handle %d to app pid: %d with ret %d",
@@
-435,7
+436,9
@@
int ust_consumer_send_channel_to_ust(struct ust_app *app,
app->sock, app->pid, channel->name, channel->tracing_channel_id);
/* Send stream to application. */
app->sock, app->pid, channel->name, channel->tracing_channel_id);
/* Send stream to application. */
+ pthread_mutex_lock(&app->sock_lock);
ret = ustctl_send_channel_to_ust(app->sock, ua_sess->handle, channel->obj);
ret = ustctl_send_channel_to_ust(app->sock, ua_sess->handle, channel->obj);
+ pthread_mutex_unlock(&app->sock_lock);
if (ret < 0) {
if (ret != -EPIPE && ret != -LTTNG_UST_ERR_EXITING) {
ERR("Error ustctl send channel %s to app pid: %d with ret %d",
if (ret < 0) {
if (ret != -EPIPE && ret != -LTTNG_UST_ERR_EXITING) {
ERR("Error ustctl send channel %s to app pid: %d with ret %d",
This page took
0.027596 seconds
and
4
git commands to generate.