projects
/
platform
/
core
/
graphics
/
tizenvg.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
c1062fc
)
tvg_saver TvgSaver: Initialize local value
author
JunsuChoi
<jsuya.choi@samsung.com>
Mon, 8 Nov 2021 06:05:16 +0000
(15:05 +0900)
committer
JunsuChoi
<jsuya.choi@samsung.com>
Wed, 10 Nov 2021 01:43:08 +0000
(10:43 +0900)
If paint has no path information or stroke information,
it is not referenced inside bounds.
This will access the uninitialized variable at line 759, 760.
src/savers/tvg/tvgTvgSaver.cpp
patch
|
blob
|
history
diff --git
a/src/savers/tvg/tvgTvgSaver.cpp
b/src/savers/tvg/tvgTvgSaver.cpp
index
e206994
..
d7c9798
100644
(file)
--- a/
src/savers/tvg/tvgTvgSaver.cpp
+++ b/
src/savers/tvg/tvgTvgSaver.cpp
@@
-752,6
+752,7
@@
bool TvgSaver::save(Paint* paint, const string& path, bool compress)
if (!this->path) return false;
float x, y;
+ x = y = 0;
paint->bounds(&x, &y, &vsize[0], &vsize[1], false);
//cut off the negative space