]> git.ipfire.org Git - thirdparty/samba.git/commitdiff
net_ads_gpo: remove old '#if 0' blocks
authorDouglas Bagnall <douglas.bagnall@catalyst.net.nz>
Fri, 10 Jan 2020 03:06:33 +0000 (16:06 +1300)
committerGary Lockyer <gary@samba.org>
Mon, 13 Jan 2020 23:52:26 +0000 (23:52 +0000)
I think the dump_gpo() calls do enough, and this code has done nothing
for a decade.

Signed-off-by: Douglas Bagnall <douglas.bagnall@catalyst.net.nz>
Reviewed-by: Gary Lockyer <gary@catalyst.net.nz>
Autobuild-User(master): Gary Lockyer <gary@samba.org>
Autobuild-Date(master): Mon Jan 13 23:52:26 UTC 2020 on sn-devel-184

source3/utils/net_ads_gpo.c

index cd77f93ffd372d97737bbeae92ea52286aea6614..4a2d19a4ba584451bc92afafb8edadd349a376d2 100644 (file)
@@ -134,29 +134,7 @@ static int net_ads_gpo_refresh(struct net_context *c, int argc, const char **arg
                d_printf(_("* dumping GPO list\n"));
 
                for (gpo = gpo_list; gpo; gpo = gpo->next) {
-
                        dump_gpo(gpo, 0);
-#if 0
-               char *server, *share, *nt_path, *unix_path;
-
-               d_printf("--------------------------------------\n");
-               d_printf("Name:\t\t\t%s\n", gpo->display_name);
-               d_printf("LDAP GPO version:\t%d (user: %d, machine: %d)\n",
-                       gpo->version,
-                       GPO_VERSION_USER(gpo->version),
-                       GPO_VERSION_MACHINE(gpo->version));
-
-               result = gpo_explode_filesyspath(mem_ctx, gpo->file_sys_path,
-                                                &server, &share, &nt_path,
-                                                &unix_path);
-               if (!NT_STATUS_IS_OK(result)) {
-                       d_printf("got: %s\n", nt_errstr(result));
-               }
-
-               d_printf("GPO stored on server: %s, share: %s\n", server, share);
-               d_printf("\tremote path:\t%s\n", nt_path);
-               d_printf("\tlocal path:\t%s\n", unix_path);
-#endif
                }
        }
 
@@ -179,30 +157,7 @@ static int net_ads_gpo_refresh(struct net_context *c, int argc, const char **arg
                d_printf(_("* dumping GPO list from registry\n"));
 
                for (gpo = read_list; gpo; gpo = gpo->next) {
-
                        dump_gpo(gpo, 0);
-
-#if 0
-               char *server, *share, *nt_path, *unix_path;
-
-               d_printf("--------------------------------------\n");
-               d_printf("Name:\t\t\t%s\n", gpo->display_name);
-               d_printf("LDAP GPO version:\t%d (user: %d, machine: %d)\n",
-                       gpo->version,
-                       GPO_VERSION_USER(gpo->version),
-                       GPO_VERSION_MACHINE(gpo->version));
-
-               result = gpo_explode_filesyspath(mem_ctx, gpo->file_sys_path,
-                                                &server, &share, &nt_path,
-                                                &unix_path);
-               if (!NT_STATUS_IS_OK(result)) {
-                       d_printf("got: %s\n", nt_errstr(result));
-               }
-
-               d_printf("GPO stored on server: %s, share: %s\n", server, share);
-               d_printf("\tremote path:\t%s\n", nt_path);
-               d_printf("\tlocal path:\t%s\n", unix_path);
-#endif
                }
        }