summaryrefslogtreecommitdiff
path: root/gdhcp
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2010-09-11 12:35:42 +0200
committerMarcel Holtmann <marcel@holtmann.org>2010-09-11 12:35:42 +0200
commitbae6cdc4e55f1523b1602159331b73a3deb86984 (patch)
tree0f9b65b4097d8c53cec23339ed42bf0e73ee7db8 /gdhcp
parentd7cfdc4c15465b8581329f57da9ec6b47208ea03 (diff)
downloadconnman-bae6cdc4e55f1523b1602159331b73a3deb86984.tar.gz
connman-bae6cdc4e55f1523b1602159331b73a3deb86984.tar.bz2
connman-bae6cdc4e55f1523b1602159331b73a3deb86984.zip
Handle potential NULL pointer with DHCP options
Diffstat (limited to 'gdhcp')
-rw-r--r--gdhcp/client.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gdhcp/client.c b/gdhcp/client.c
index 430ecc86..1919af79 100644
--- a/gdhcp/client.c
+++ b/gdhcp/client.c
@@ -913,6 +913,9 @@ static GList *get_option_value_list(char *value)
char *pos = value;
GList *list = NULL;
+ if (pos == NULL)
+ return NULL;
+
while ((pos = strchr(pos, ' ')) != NULL) {
*pos = '\0';