Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
VTK
Project overview
Project overview
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Scott Wittenburg
VTK
Commits
479a0e20
Commit
479a0e20
authored
Dec 08, 2018
by
Sean McBride
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed buffer overrun by using vsnprintf instead of vsprintf
parent
4cb5e34c
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
Common/System/vtkTimerLog.cxx
Common/System/vtkTimerLog.cxx
+1
-1
Common/System/vtkTimerLog.h
Common/System/vtkTimerLog.h
+1
-1
No files found.
Common/System/vtkTimerLog.cxx
View file @
479a0e20
...
...
@@ -124,7 +124,7 @@ void vtkTimerLog::FormatAndMarkEvent(const char *format, ...)
static
char
event
[
4096
];
va_list
var_args
;
va_start
(
var_args
,
format
);
vs
printf
(
event
,
format
,
var_args
);
vs
nprintf
(
event
,
sizeof
(
event
)
,
format
,
var_args
);
va_end
(
var_args
);
vtkTimerLog
::
MarkEventInternal
(
event
,
vtkTimerLogEntry
::
STANDALONE
);
...
...
Common/System/vtkTimerLog.h
View file @
479a0e20
...
...
@@ -109,7 +109,7 @@ public:
/**
* Record a timing event. The event is represented by a formatted
* string.
* string.
The internal buffer is 4096 bytes and will truncate anything longer.
*/
#ifndef __VTK_WRAP__
static
void
FormatAndMarkEvent
(
const
char
*
EventString
,
...)
VTK_FORMAT_PRINTF
(
1
,
2
);
...
...
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