Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
B
bcc
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
bcc
Commits
af66546d
Commit
af66546d
authored
Mar 28, 2016
by
Brenden Blanco
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #449 from goldshtn/tp-str-fix
Fixed bug around local assignment from char array
parents
c256e94d
67a644bc
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
5 additions
and
0 deletions
+5
-0
src/python/bcc/tracepoint.py
src/python/bcc/tracepoint.py
+5
-0
No files found.
src/python/bcc/tracepoint.py
View file @
af66546d
...
...
@@ -147,6 +147,11 @@ struct %s {
def _generate_struct_locals(self):
text = ""
for field_type, field_name in self.struct_fields:
if field_type == "char" and field_name.endswith('
]
'):
# Special case for '
char
whatever
[
N
]
', should
# be assigned to a '
char
*
'
field_type = "char *"
field_name = re.sub(r'
\
[
\
d
+
\
]
$
', '', field_name)
text += " %s %s = tp.%s;
\
n
" % (
field_type, field_name, field_name)
return text
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment