diff options
author | Günther Deschner <gd@samba.org> | 2006-09-29 17:15:45 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 12:14:55 -0500 |
commit | 88a98e35c780b1665bc21006b9c8c096e6b06f3f (patch) | |
tree | c77114ee5057bb91015c36855194cac1c056670d /source3/libgpo | |
parent | 824966fb3c88958b851b9ac5c29d95f770d98429 (diff) | |
download | samba-88a98e35c780b1665bc21006b9c8c096e6b06f3f.tar.gz samba-88a98e35c780b1665bc21006b9c8c096e6b06f3f.tar.bz2 samba-88a98e35c780b1665bc21006b9c8c096e6b06f3f.zip |
r19003: Finally activate "net ads gpo".
For those who are interested, try
net ads gpo refresh mybox$
to get your machine related GPOs downloaded to /var/lib/samba/gpo_cache.
Detailed information about GPOs is currently only printed when setting a
higher debuglevel then 0.
Guenther
(This used to be commit d086babf9d2592f041cc35db3d60b4452ea953f5)
Diffstat (limited to 'source3/libgpo')
-rw-r--r-- | source3/libgpo/gpo_util.c | 26 |
1 files changed, 13 insertions, 13 deletions
diff --git a/source3/libgpo/gpo_util.c b/source3/libgpo/gpo_util.c index 4c74d10031..bd11becad0 100644 --- a/source3/libgpo/gpo_util.c +++ b/source3/libgpo/gpo_util.c @@ -167,31 +167,31 @@ const char *cse_snapin_gpo_guid_string_to_name(const char *guid) return snapin_guid_string_to_name(guid, gpo_cse_snapin_extensions); } -void dump_gp_ext(struct GP_EXT *gp_ext) +void dump_gp_ext(struct GP_EXT *gp_ext, int debuglevel) { - int lvl = 10; + int lvl = debuglevel; int i; if (gp_ext == NULL) { return; } - DEBUG(lvl,("---------------------\n\n")); - DEBUGADD(lvl,("name:\t\t\t%s\n", gp_ext->gp_extension)); + DEBUG(lvl,("\t---------------------\n\n")); + DEBUGADD(lvl,("\tname:\t\t\t%s\n", gp_ext->gp_extension)); for (i=0; i< gp_ext->num_exts; i++) { - DEBUGADD(lvl,("extension:\t\t\t%s\n", gp_ext->extensions_guid[i])); - DEBUGADD(lvl,("extension (name):\t\t\t%s\n", gp_ext->extensions[i])); + DEBUGADD(lvl,("\textension:\t\t\t%s\n", gp_ext->extensions_guid[i])); + DEBUGADD(lvl,("\textension (name):\t\t\t%s\n", gp_ext->extensions[i])); - DEBUGADD(lvl,("snapin:\t\t\t%s\n", gp_ext->snapins_guid[i])); - DEBUGADD(lvl,("snapin (name):\t\t\t%s\n", gp_ext->snapins[i])); + DEBUGADD(lvl,("\tsnapin:\t\t\t%s\n", gp_ext->snapins_guid[i])); + DEBUGADD(lvl,("\tsnapin (name):\t\t\t%s\n", gp_ext->snapins[i])); } } -void dump_gpo(TALLOC_CTX *mem_ctx, struct GROUP_POLICY_OBJECT *gpo) +void dump_gpo(TALLOC_CTX *mem_ctx, struct GROUP_POLICY_OBJECT *gpo, int debuglevel) { - int lvl = 1; + int lvl = debuglevel; if (gpo == NULL) { return; @@ -251,7 +251,7 @@ void dump_gpo(TALLOC_CTX *mem_ctx, struct GROUP_POLICY_OBJECT *gpo) if (!ADS_ERR_OK(status)) { return; } - dump_gp_ext(&gp_ext); + dump_gp_ext(&gp_ext, lvl); } if (gpo->user_extensions) { @@ -265,7 +265,7 @@ void dump_gpo(TALLOC_CTX *mem_ctx, struct GROUP_POLICY_OBJECT *gpo) if (!ADS_ERR_OK(status)) { return; } - dump_gp_ext(&gp_ext); + dump_gp_ext(&gp_ext, lvl); } }; @@ -321,7 +321,7 @@ void dump_gplink(ADS_STRUCT *ads, TALLOC_CTX *mem_ctx, struct GP_LINK *gp_link) DEBUG(lvl,("get gpo for %s failed: %s\n", gp_link->link_names[i], ads_errstr(status))); return; } - dump_gpo(mem_ctx, &gpo); + dump_gpo(mem_ctx, &gpo, lvl); } } } |