projects
/
platform
/
core
/
appfw
/
tizen-core.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
8c66010
)
Fix heap use after free issue
17/317517/1
author
Changgyu Choi
<changyu.choi@samsung.com>
Fri, 3 Jan 2025 04:30:18 +0000
(13:30 +0900)
committer
Changgyu Choi
<changyu.choi@samsung.com>
Fri, 3 Jan 2025 04:30:18 +0000
(13:30 +0900)
To resolve UAF issue, source object must be maintained until end of the UnrefSelf().
Change-Id: If8017e0bb220f4f63f4cd771f46ebf8110c8fcdc
Signed-off-by: Changgyu Choi <changyu.choi@samsung.com>
src/tizen-core/stub.cc
patch
|
blob
|
history
diff --git
a/src/tizen-core/stub.cc
b/src/tizen-core/stub.cc
index 9bf2ce16a50e98074c698474b1d5d114871d9cdc..2f0aeb7273ec65e613d4e668e8d1d7128b35990a 100644
(file)
--- a/
src/tizen-core/stub.cc
+++ b/
src/tizen-core/stub.cc
@@
-466,7
+466,7
@@
API int tizen_core_source_destroy(tizen_core_source_h source) {
return TIZEN_CORE_ERROR_INVALID_PARAMETER;
}
- auto
* handle = static_cast<SourceExt*>(source
);
+ auto
handle = static_cast<SourceExt*>(source)->shared_from_this(
);
handle->UnrefSelf();
return TIZEN_CORE_ERROR_NONE;
}