From: Patrick G. Bridges Date: Tue, 19 Feb 2013 16:04:12 +0000 (-0700) Subject: Added null check to option processing call. X-Git-Url: http://v3vee.org/palacios/gitweb/gitweb.cgi?a=commitdiff_plain;h=e86fcd72dd75d5a2fee791046f87ffd3ac454285;p=palacios.git Added null check to option processing call. --- diff --git a/palacios/src/palacios/vmm.c b/palacios/src/palacios/vmm.c index c5a7f00..86b149a 100644 --- a/palacios/src/palacios/vmm.c +++ b/palacios/src/palacios/vmm.c @@ -125,9 +125,13 @@ void V3_parse_options(char *options) { char *currKey = NULL, *currVal = NULL; int parseKey = 1; - int len = strlen(options); + int len; char *c; + if (!options) { + return; + } + len = strlen(options); option_storage = V3_Malloc(len + 1); strcpy(option_storage, options); c = option_storage;