diff options
author | Gerald Carter <jerry@samba.org> | 2005-07-20 15:35:29 +0000 |
---|---|---|
committer | Gerald (Jerry) Carter <jerry@samba.org> | 2007-10-10 11:00:14 -0500 |
commit | cd961e50a3029898868d21263ccacb7d5f1f07b9 (patch) | |
tree | b47fc8933aa95a41c564255bd52d1d8b57283531 /source/libads | |
parent | 2720c82a950a0afded25c2c161cda47ea412fea3 (diff) | |
download | samba-cd961e50a3029898868d21263ccacb7d5f1f07b9.tar.gz samba-cd961e50a3029898868d21263ccacb7d5f1f07b9.tar.xz samba-cd961e50a3029898868d21263ccacb7d5f1f07b9.zip |
r8654: merging cli_spoolss_XX() updates from trunk
Diffstat (limited to 'source/libads')
-rw-r--r-- | source/libads/ldap_printer.c | 21 |
1 files changed, 3 insertions, 18 deletions
diff --git a/source/libads/ldap_printer.c b/source/libads/ldap_printer.c index 68e67358910..6b053f8b4a3 100644 --- a/source/libads/ldap_printer.c +++ b/source/libads/ldap_printer.c @@ -267,7 +267,7 @@ WERROR get_remote_printer_publishing_data(struct cli_state *cli, char *printername, *servername; REGVAL_CTR dsdriver_ctr, dsspooler_ctr; BOOL got_dsdriver = False, got_dsspooler = False; - uint32 needed, i; + uint32 i; POLICY_HND pol; asprintf(&servername, "\\\\%s", cli->desthost); @@ -286,14 +286,7 @@ WERROR get_remote_printer_publishing_data(struct cli_state *cli, return result; } - result = cli_spoolss_enumprinterdataex(cli, mem_ctx, 0, &needed, - &pol, SPOOL_DSDRIVER_KEY, NULL); - - if (W_ERROR_V(result) == ERRmoredata) - result = cli_spoolss_enumprinterdataex(cli, mem_ctx, needed, - NULL, &pol, - SPOOL_DSDRIVER_KEY, - &dsdriver_ctr); + result = cli_spoolss_enumprinterdataex(cli, mem_ctx, &pol, SPOOL_DSDRIVER_KEY, NULL); if (!W_ERROR_IS_OK(result)) { DEBUG(3, ("Unable to do enumdataex on %s, error is %s.\n", @@ -307,15 +300,7 @@ WERROR get_remote_printer_publishing_data(struct cli_state *cli, dsdriver_ctr.values[i]); } - result = cli_spoolss_enumprinterdataex(cli, mem_ctx, 0, &needed, - &pol, SPOOL_DSSPOOLER_KEY, - NULL); - - if (W_ERROR_V(result) == ERRmoredata) - result = cli_spoolss_enumprinterdataex(cli, mem_ctx, needed, - NULL, &pol, - SPOOL_DSSPOOLER_KEY, - &dsspooler_ctr); + result = cli_spoolss_enumprinterdataex(cli, mem_ctx, &pol, SPOOL_DSSPOOLER_KEY, NULL); if (!W_ERROR_IS_OK(result)) { DEBUG(3, ("Unable to do enumdataex on %s, error is %s.\n", |