Skip to content

Commit 3446b72

Browse files
committed
Fix
1 parent f63357f commit 3446b72

File tree

2 files changed

+8
-7
lines changed

2 files changed

+8
-7
lines changed

lib/Core/Executor.cpp

+7-5
Original file line numberDiff line numberDiff line change
@@ -5037,8 +5037,9 @@ void Executor::terminateStateOnTargetTaintError(ExecutionState &state,
50375037
reportStateOnTargetError(
50385038
state, ReachWithError(ReachWithErrorType::MaybeTaint, ruleStr));
50395039

5040-
terminateStateOnProgramError(state, ruleStr + " taint error",
5041-
StateTerminationType::Taint);
5040+
terminateStateOnProgramError(
5041+
state, new ErrorEvent(locationOf(state), StateTerminationType::Taint,
5042+
ruleStr + " taint error"));
50425043
}
50435044

50445045
void Executor::terminateStateOnError(ExecutionState &state,
@@ -5569,9 +5570,10 @@ void Executor::executeChangeTaintSource(ExecutionState &state,
55695570

55705571
ObjectState *wos = it->second->addressSpace.getWriteable(mo, os.get());
55715572
if (wos->readOnly) {
5572-
terminateStateOnProgramError(*(it->second),
5573-
"memory error: object read only",
5574-
StateTerminationType::ReadOnly);
5573+
terminateStateOnProgramError(
5574+
*(it->second), new ErrorEvent(locationOf(*(it->second)),
5575+
StateTerminationType::ReadOnly,
5576+
"memory error: object read only"));
55755577
} else {
55765578
wos->updateTaint(Expr::createTaintBySource(source), isAdd);
55775579
errs() << "source was: " << source << " ";

lib/Core/Memory.cpp

+1-2
Original file line numberDiff line numberDiff line change
@@ -254,8 +254,7 @@ ref<Expr> ObjectState::readTaint8(ref<Expr> offset) const {
254254
dyn_cast<ConstantExpr>(object->getSizeExpr())) {
255255
auto moSize = sizeExpr->getZExtValue();
256256
if (object && moSize > 4096) {
257-
std::string allocInfo;
258-
object->getAllocInfo(allocInfo);
257+
std::string allocInfo = object->getAllocInfo();
259258
klee_warning_once(nullptr,
260259
"Symbolic memory access will send the following "
261260
"array of %lu bytes to "

0 commit comments

Comments
 (0)