Skip to content

Commit 2e6328a

Browse files
committed
Addressing PR comment and possible problem
1 parent 1e93643 commit 2e6328a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

devicedefender/source/DeviceDefender.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,9 +45,9 @@ namespace Aws
4545
{
4646
(void)networkConnectionSamplePeriodSeconds;
4747
struct aws_byte_cursor thingNameCursor = Crt::ByteCursorFromString(thingName);
48-
m_lastError =
48+
int return_code =
4949
aws_iotdevice_defender_config_create(&m_taskConfig, allocator, &thingNameCursor, reportFormat);
50-
if (AWS_OP_SUCCESS == m_lastError)
50+
if (AWS_OP_SUCCESS == return_code)
5151
{
5252
aws_iotdevice_defender_config_set_task_cancelation_fn(m_taskConfig, s_onDefenderV1TaskCancelled);
5353
aws_iotdevice_defender_config_set_callback_userdata(m_taskConfig, this);

0 commit comments

Comments
 (0)