Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 169494
b: refs/heads/master
c: 924a79a
h: refs/heads/master
v: v3
  • Loading branch information
Steven Rostedt authored and Ingo Molnar committed Oct 15, 2009
1 parent fa8becd commit d4c7952
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b226f744d40b052ac126c4cb16c76f66e5185128
refs/heads/master: 924a79af2cdee26a034b9bdce8c9c76995b5c901
16 changes: 16 additions & 0 deletions trunk/tools/perf/util/trace-event-parse.c
Original file line number Diff line number Diff line change
Expand Up @@ -1734,6 +1734,7 @@ static int event_read_print(struct event *event)
if (read_expect_type(EVENT_DQUOTE, &token) < 0)
goto fail;

concat:
event->print_fmt.format = token;
event->print_fmt.args = NULL;

Expand All @@ -1743,6 +1744,21 @@ static int event_read_print(struct event *event)
if (type == EVENT_NONE)
return 0;

/* Handle concatination of print lines */
if (type == EVENT_DQUOTE) {
char *cat;

cat = malloc_or_die(strlen(event->print_fmt.format) +
strlen(token) + 1);
strcpy(cat, event->print_fmt.format);
strcat(cat, token);
free_token(token);
free_token(event->print_fmt.format);
event->print_fmt.format = NULL;
token = cat;
goto concat;
}

if (test_type_token(type, token, EVENT_DELIM, (char *)","))
goto fail;

Expand Down

0 comments on commit d4c7952

Please sign in to comment.