Honor ExcludeNilProperties as per-request counterpart to
cim:omit_schema_optional

diff --git a/src/plugins/cim/cim_data_stubs.c b/src/plugins/cim/cim_data_stubs.c
index d4eb7aa..f834b69 100644
--- a/src/plugins/cim/cim_data_stubs.c
+++ b/src/plugins/cim/cim_data_stubs.c
@@ -97,6 +97,7 @@
 	char *_tmp = NULL;
 	char *resource_uri = NULL;
 	char *show_extensions;
+	char *exclude_nil_properties;
 	CimClientInfo *cimclient= (CimClientInfo *)u_zalloc(sizeof(CimClientInfo));
 	if(!cimclient){
 		return NULL;
@@ -149,6 +150,11 @@
 	if (show_extensions && strcmp(show_extensions, "true") == 0) {
 		cimclient->flags |= FLAG_CIM_EXTENSIONS;
 	}
+	
+	exclude_nil_properties = wsman_get_option_set(cntx, NULL, WSMB_EXCLUDE_NIL_PROPS);
+	if (exclude_nil_properties && strcmp(exclude_nil_properties, "true") == 0) {
+		cimclient->flags |= FLAG_CIM_SCHEMA_OPT;
+	}
 	if (get_omit_schema_optional() == 1) {
 		cimclient->flags |= FLAG_CIM_SCHEMA_OPT;
 	}