projects
/
platform
/
core
/
appfw
/
app-installers.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
21c6391
)
Add exception handling to StepSignature
25/280125/1
author
Ilho Kim
<ilho159.kim@samsung.com>
Wed, 24 Aug 2022 07:06:17 +0000
(16:06 +0900)
committer
Ilho Kim
<ilho159.kim@samsung.com>
Wed, 24 Aug 2022 07:06:17 +0000
(16:06 +0900)
If StepSignature's precheck fails, the variable 'signature_' is not initialized
Change-Id: Ie605111e8572e6d7ccf5e8e161fa5e6f29b13dee
Signed-off-by: Ilho Kim <ilho159.kim@samsung.com>
src/common/step/security/step_signature.cc
patch
|
blob
|
history
diff --git
a/src/common/step/security/step_signature.cc
b/src/common/step/security/step_signature.cc
index
6c7abdd
..
3a63882
100644
(file)
--- a/
src/common/step/security/step_signature.cc
+++ b/
src/common/step/security/step_signature.cc
@@
-132,6
+132,9
@@
Step::Status StepSignature::process() {
}
Step::Status StepSignature::undo() {
+ if (signature_ == nullptr)
+ return Step::Status::OK;
+
bf::remove(signature_->GetFilePath());
if (bf::exists(signature_->GetBackupPath()))
bf::rename(signature_->GetBackupPath(), signature_->GetFilePath());