projects
/
lttv.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
change has_alignment for alignment
[lttv.git]
/
ltt
/
branches
/
poly
/
ltt
/
marker.c
diff --git
a/ltt/branches/poly/ltt/marker.c
b/ltt/branches/poly/ltt/marker.c
index f1053d8ccdb850346eb587071110d97d3cd38bc8..3e2ab3d68cd4c98cbbac008dd31bf662085dc4e6 100644
(file)
--- a/
ltt/branches/poly/ltt/marker.c
+++ b/
ltt/branches/poly/ltt/marker.c
@@
-267,11
+267,17
@@
long marker_update_fields_offsets(struct marker_info *info, const char *data)
unsigned int i;
long offset = 0;
unsigned int i;
long offset = 0;
- for (i = 0; i < info->fields->len; i++) {
+ /* Find the last field with a static offset, then update from there. */
+ for (i = info->fields->len - 1; i >= 0; i--) {
field = &g_array_index(info->fields, struct marker_field, i);
field = &g_array_index(info->fields, struct marker_field, i);
+ if (field->static_offset) {
+ offset = field->offset;
+ break;
+ }
+ }
- if (field->static_offset)
-
continue
;
+ for (; i < info->fields->len; i++) {
+
field = &g_array_index(info->fields, struct marker_field, i)
;
switch (field->type) {
case LTT_TYPE_SIGNED_INT:
switch (field->type) {
case LTT_TYPE_SIGNED_INT:
@@
-346,7
+352,7
@@
static void format_parse(const char *fmt, struct marker_info *info)
}
break;
case ' ':
}
break;
case ' ':
- if (name_end && name_begin) {
+ if (
!
name_end && name_begin) {
name_end = fmt;
if (name)
g_free(name);
name_end = fmt;
if (name)
g_free(name);
@@
-356,7
+362,7
@@
static void format_parse(const char *fmt, struct marker_info *info)
}
break; /* Skip white spaces */
default:
}
break; /* Skip white spaces */
default:
- if (!name) {
+ if (!name
_begin
) {
name_begin = fmt;
name_end = NULL;
}
name_begin = fmt;
name_end = NULL;
}
This page took
0.024328 seconds
and
4
git commands to generate.