aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/conftest/hooks/add_notify.c2
-rw-r--r--src/conftest/hooks/add_payload.c2
-rw-r--r--src/conftest/hooks/unencrypted_notify.c2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/conftest/hooks/add_notify.c b/src/conftest/hooks/add_notify.c
index 4ae7c2db7..00833265f 100644
--- a/src/conftest/hooks/add_notify.c
+++ b/src/conftest/hooks/add_notify.c
@@ -85,7 +85,7 @@ METHOD(listener_t, message, bool,
data = chunk_skip(chunk_create(this->data, strlen(this->data)), 2);
data = chunk_from_hex(data, NULL);
}
- else if (data.len)
+ else if (this->data && strlen(this->data))
{
data = chunk_clone(chunk_create(this->data, strlen(this->data)));
}
diff --git a/src/conftest/hooks/add_payload.c b/src/conftest/hooks/add_payload.c
index 132bac7c5..9de18c52e 100644
--- a/src/conftest/hooks/add_payload.c
+++ b/src/conftest/hooks/add_payload.c
@@ -82,7 +82,7 @@ METHOD(listener_t, message, bool,
data = chunk_skip(chunk_create(this->data, strlen(this->data)), 2);
data = chunk_from_hex(data, NULL);
}
- else if (data.len)
+ else if (this->data && strlen(this->data))
{
data = chunk_clone(chunk_create(this->data, strlen(this->data)));
}
diff --git a/src/conftest/hooks/unencrypted_notify.c b/src/conftest/hooks/unencrypted_notify.c
index 1d7f42def..8737158ad 100644
--- a/src/conftest/hooks/unencrypted_notify.c
+++ b/src/conftest/hooks/unencrypted_notify.c
@@ -80,7 +80,7 @@ METHOD(listener_t, ike_updown, bool,
data = chunk_skip(chunk_create(this->data, strlen(this->data)), 2);
data = chunk_from_hex(data, NULL);
}
- else if (data.len)
+ else if (this->data && strlen(this->data))
{
data = chunk_clone(chunk_create(this->data, strlen(this->data)));
}