summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/libads/ldap_printer.c40
1 files changed, 14 insertions, 26 deletions
diff --git a/source3/libads/ldap_printer.c b/source3/libads/ldap_printer.c
index b5a3e6ba43..d5290b23a9 100644
--- a/source3/libads/ldap_printer.c
+++ b/source3/libads/ldap_printer.c
@@ -346,19 +346,13 @@ WERROR get_remote_printer_publishing_data(struct rpc_pipe_client *cli,
/* Have the data we need now, so start building */
for (i=0; i < count; i++) {
struct regval_blob v;
- DATA_BLOB blob;
-
- result = push_spoolss_PrinterData(mem_ctx, &blob,
- info[i].type,
- info[i].data);
- if (W_ERROR_IS_OK(result)) {
- fstrcpy(v.valuename, info[i].value_name);
- v.type = info[i].type;
- v.data_p = blob.data;
- v.size = blob.length;
-
- map_regval_to_ads(mem_ctx, mods, &v);
- }
+
+ fstrcpy(v.valuename, info[i].value_name);
+ v.type = info[i].type;
+ v.data_p = info[i].data->data;
+ v.size = info[i].data->length;
+
+ map_regval_to_ads(mem_ctx, mods, &v);
}
}
@@ -373,19 +367,13 @@ WERROR get_remote_printer_publishing_data(struct rpc_pipe_client *cli,
} else {
for (i=0; i < count; i++) {
struct regval_blob v;
- DATA_BLOB blob = data_blob_null;
-
- result = push_spoolss_PrinterData(mem_ctx, &blob,
- info[i].type,
- info[i].data);
- if (W_ERROR_IS_OK(result)) {
- fstrcpy(v.valuename, info[i].value_name);
- v.type = info[i].type;
- v.data_p = blob.data;
- v.size = blob.length;
-
- map_regval_to_ads(mem_ctx, mods, &v);
- }
+
+ fstrcpy(v.valuename, info[i].value_name);
+ v.type = info[i].type;
+ v.data_p = info[i].data->data;
+ v.size = info[i].data->length;
+
+ map_regval_to_ads(mem_ctx, mods, &v);
}
}