projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Add Trace CTF IR type
[babeltrace.git]
/
formats
/
ctf
/
ir
/
stream.c
diff --git
a/formats/ctf/ir/stream.c
b/formats/ctf/ir/stream.c
index d9bd5ef87b0950ef0fb60b63a189196ab7d2b33c..57b893790ae36ca2a8e2122b72f083111ad31adf 100644
(file)
--- a/
formats/ctf/ir/stream.c
+++ b/
formats/ctf/ir/stream.c
@@
-326,7
+326,11
@@
int bt_ctf_stream_flush(struct bt_ctf_stream *stream)
struct bt_ctf_field *integer = NULL;
struct ctf_stream_pos packet_context_pos;
struct bt_ctf_field *integer = NULL;
struct ctf_stream_pos packet_context_pos;
- if (!stream) {
+ if (!stream || stream->pos.fd < 0) {
+ /*
+ * Stream does not have an associated fd. It is,
+ * therefore, not a stream being used to write events.
+ */
ret = -1;
goto end;
}
ret = -1;
goto end;
}
This page took
0.024628 seconds
and
4
git commands to generate.