Skip to content
Browse files

3315 svccfg export -a drops values in PG "general"

Reviewed by: Eric Schrock <eric.schrock@delphix.com>
Reviewed by: Dan McDonald <danmcd@nexenta.com>
Approved by: Richard Lowe <richlowe@richlowe.net>
  • Loading branch information...
1 parent 7932179 commit 24ed8e4e1f55d1001c43ec0a2a8a02f90204bf05 @wesolows wesolows committed with richlowe Dec 20, 2012
Showing with 28 additions and 21 deletions.
  1. +28 −21 usr/src/cmd/svc/svccfg/svccfg_libscf.c
View
49 usr/src/cmd/svc/svccfg/svccfg_libscf.c
@@ -9081,7 +9081,7 @@ export_dependency(scf_propertygroup_t *pg, struct entity_elts *eelts)
if (err) {
xmlFreeNode(n);
- export_pg(pg, eelts, 0);
+ export_pg(pg, eelts, SCE_ALL_VALUES);
return;
}
@@ -9116,7 +9116,7 @@ export_dependency(scf_propertygroup_t *pg, struct entity_elts *eelts)
xmlFreeNode(m);
}
- export_property(exp_prop, exp_str, &elts, 0);
+ export_property(exp_prop, exp_str, &elts, SCE_ALL_VALUES);
}
if (ret == -1)
scfdie();
@@ -9244,7 +9244,7 @@ export_method(scf_propertygroup_t *pg, struct entity_elts *eelts)
if (err) {
xmlFreeNode(n);
- export_pg(pg, eelts, 0);
+ export_pg(pg, eelts, SCE_ALL_VALUES);
return;
}
@@ -9421,7 +9421,7 @@ export_method(scf_propertygroup_t *pg, struct entity_elts *eelts)
continue;
}
- export_property(exp_prop, exp_str, &elts, 0);
+ export_property(exp_prop, exp_str, &elts, SCE_ALL_VALUES);
}
if (ret == -1)
scfdie();
@@ -9537,7 +9537,7 @@ export_svc_general(scf_propertygroup_t *pg, struct entity_elts *selts)
xmlFreeNode(s);
}
- export_property(exp_prop, exp_str, &elts, 0);
+ export_property(exp_prop, exp_str, &elts, SCE_ALL_VALUES);
}
if (ret == -1)
scfdie();
@@ -9633,7 +9633,7 @@ export_method_context(scf_propertygroup_t *pg, struct entity_elts *elts)
if (err && env == NULL) {
xmlFreeNode(n);
- export_pg(pg, elts, 0);
+ export_pg(pg, elts, SCE_ALL_VALUES);
return;
}
@@ -9747,7 +9747,7 @@ export_dependent(scf_propertygroup_t *pg, const char *name, const char *tfmri)
xmlFreeNode(s);
}
- export_property(exp_prop, exp_str, &pgelts, 0);
+ export_property(exp_prop, exp_str, &pgelts, SCE_ALL_VALUES);
}
if (ret == -1)
scfdie();
@@ -9796,7 +9796,8 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
if ((ty != SCF_TYPE_ASTRING &&
prop_check_type(exp_prop, SCF_TYPE_FMRI) != 0) ||
prop_get_val(exp_prop, exp_val) != 0) {
- export_property(exp_prop, NULL, &pgelts, 0);
+ export_property(exp_prop, NULL, &pgelts,
+ SCE_ALL_VALUES);
continue;
}
@@ -9827,7 +9828,8 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
"FMRI.\n"), fmri);
}
- export_property(exp_prop, exp_str, &pgelts, 0);
+ export_property(exp_prop, exp_str, &pgelts,
+ SCE_ALL_VALUES);
continue;
case SCF_ERROR_CONSTRAINT_VIOLATED:
@@ -9840,7 +9842,8 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
"a service or an instance.\n"), fmri);
}
- export_property(exp_prop, exp_str, &pgelts, 0);
+ export_property(exp_prop, exp_str, &pgelts,
+ SCE_ALL_VALUES);
continue;
case SCF_ERROR_NOT_FOUND:
@@ -9853,7 +9856,8 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
"not exist.\n"), fmri);
}
- export_property(exp_prop, exp_str, &pgelts, 0);
+ export_property(exp_prop, exp_str, &pgelts,
+ SCE_ALL_VALUES);
continue;
default:
@@ -9872,7 +9876,8 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
warn(gettext("Entity %s is missing dependency property "
"group %s.\n"), fmri, exp_str);
- export_property(exp_prop, NULL, &pgelts, 0);
+ export_property(exp_prop, NULL, &pgelts,
+ SCE_ALL_VALUES);
continue;
}
@@ -9886,14 +9891,16 @@ export_dependents(scf_propertygroup_t *pg, struct entity_elts *eelts)
warn(gettext("Property group %s is not of "
"expected type %s.\n"), fmri, SCF_GROUP_DEPENDENCY);
- export_property(exp_prop, NULL, &pgelts, 0);
+ export_property(exp_prop, NULL, &pgelts,
+ SCE_ALL_VALUES);
continue;
}
n = export_dependent(opg, exp_str, fmri);
- if (n == NULL)
- export_property(exp_prop, exp_str, &pgelts, 0);
- else {
+ if (n == NULL) {
+ export_property(exp_prop, exp_str, &pgelts,
+ SCE_ALL_VALUES);
+ } else {
if (eelts->dependents == NULL)
eelts->dependents = n;
else
@@ -10017,12 +10024,12 @@ export_template(scf_propertygroup_t *pg, struct entity_elts *elts,
if (strcmp(exp_str, SCF_PG_TM_COMMON_NAME) == 0) {
telts->common_name = export_tm_loctext(pg, "common_name");
if (telts->common_name == NULL)
- export_pg(pg, elts, 0);
+ export_pg(pg, elts, SCE_ALL_VALUES);
return;
} else if (strcmp(exp_str, SCF_PG_TM_DESCRIPTION) == 0) {
telts->description = export_tm_loctext(pg, "description");
if (telts->description == NULL)
- export_pg(pg, elts, 0);
+ export_pg(pg, elts, SCE_ALL_VALUES);
return;
}
@@ -10036,7 +10043,7 @@ export_template(scf_propertygroup_t *pg, struct entity_elts *elts,
make_node(&telts->documentation, "documentation");
(void) xmlAddChild(telts->documentation, child);
} else {
- export_pg(pg, elts, 0);
+ export_pg(pg, elts, SCE_ALL_VALUES);
}
}
@@ -10189,7 +10196,7 @@ export_notify_params(scf_propertygroup_t *pg, struct entity_elts *elts)
xmlFree(type[i]);
free(type);
- export_pg(pg, elts, 0);
+ export_pg(pg, elts, SCE_ALL_VALUES);
return;
} else {
@@ -10265,7 +10272,7 @@ export_inst_general(scf_propertygroup_t *pg, xmlNodePtr inode,
xmlFreeNode(rnode);
}
- export_property(exp_prop, exp_str, &pgelts, 0);
+ export_property(exp_prop, exp_str, &pgelts, SCE_ALL_VALUES);
}
if (ret == -1)
scfdie();

0 comments on commit 24ed8e4

Please sign in to comment.
Something went wrong with that request. Please try again.