projects
/
babeltrace.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Fix: add stricter checks on packet boundaries
[babeltrace.git]
/
formats
/
ctf
/
types
/
struct.c
diff --git
a/formats/ctf/types/struct.c
b/formats/ctf/types/struct.c
index b0d9e4a6eb5a5d6cae10220b1f9917da0a96f833..cbf53c1edb58a9d29a03ff449a7c7d16b8401d14 100644
(file)
--- a/
formats/ctf/types/struct.c
+++ b/
formats/ctf/types/struct.c
@@
-28,11
+28,12
@@
#include <babeltrace/ctf/types.h>
#include <babeltrace/ctf/types.h>
-int ctf_struct_rw(struct
stream_pos *ppos, struct
definition *definition)
+int ctf_struct_rw(struct
bt_stream_pos *ppos, struct bt_
definition *definition)
{
{
- struct declaration *declaration = definition->declaration;
+ struct
bt_
declaration *declaration = definition->declaration;
struct ctf_stream_pos *pos = ctf_pos(ppos);
struct ctf_stream_pos *pos = ctf_pos(ppos);
- ctf_align_pos(pos, declaration->alignment);
+ if (!ctf_align_pos(pos, declaration->alignment))
+ return -EFAULT;
return bt_struct_rw(ppos, definition);
}
return bt_struct_rw(ppos, definition);
}
This page took
0.022952 seconds
and
4
git commands to generate.