projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: warning, may be used uninitialized
[babeltrace.git]
/
formats
/
lttng-live
/
lttng-live-comm.c
diff --git
a/formats/lttng-live/lttng-live-comm.c
b/formats/lttng-live/lttng-live-comm.c
index d60126f4dd981c18097996611c497ffe9b8d712d..e339add6e6981a767e403661440c151ec48ba02a 100644
(file)
--- a/
formats/lttng-live/lttng-live-comm.c
+++ b/
formats/lttng-live/lttng-live-comm.c
@@
-26,7
+26,6
@@
#include <netinet/in.h>
#include <netdb.h>
#include <stdio.h>
#include <netinet/in.h>
#include <netdb.h>
#include <stdio.h>
-#include <string.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
#include <stdlib.h>
#include <unistd.h>
#include <errno.h>
@@
-52,6
+51,8
@@
#include <formats/ctf/events-private.h>
#include <babeltrace/compat/memstream.h>
#include <formats/ctf/events-private.h>
#include <babeltrace/compat/memstream.h>
+#include <babeltrace/compat/send.h>
+#include <babeltrace/compat/string.h>
#include "lttng-live.h"
#include "lttng-viewer-abi.h"
#include "lttng-live.h"
#include "lttng-viewer-abi.h"
@@
-103,7
+104,7
@@
ssize_t lttng_live_send(int fd, const void *buf, size_t len)
ssize_t ret;
do {
ssize_t ret;
do {
- ret =
send(fd, buf, len, MSG_NOSIGNAL
);
+ ret =
bt_send_nosigpipe(fd, buf, len
);
} while (ret < 0 && errno == EINTR);
return ret;
}
} while (ret < 0 && errno == EINTR);
return ret;
}
@@
-277,8
+278,8
@@
void update_session_list(GPtrArray *session_list, char *hostname,
return;
relay_session = g_new0(struct lttng_live_relay_session, 1);
return;
relay_session = g_new0(struct lttng_live_relay_session, 1);
- relay_session->hostname = strndup(hostname, MAXNAMLEN);
- relay_session->name = strndup(session_name, MAXNAMLEN);
+ relay_session->hostname =
bt_
strndup(hostname, MAXNAMLEN);
+ relay_session->name =
bt_
strndup(session_name, MAXNAMLEN);
relay_session->clients = clients;
relay_session->streams = streams;
relay_session->timer = timer;
relay_session->clients = clients;
relay_session->streams = streams;
relay_session->timer = timer;
@@
-1117,7
+1118,7
@@
int handle_seek_position(size_t index, int whence,
struct ctf_stream_pos *pos,
struct ctf_file_stream *file_stream)
{
struct ctf_stream_pos *pos,
struct ctf_file_stream *file_stream)
{
- int ret;
+ int ret
= 0
;
switch (whence) {
case SEEK_CUR:
switch (whence) {
case SEEK_CUR:
This page took
0.025803 seconds
and
4
git commands to generate.