diff options
Diffstat (limited to 'librpc/ndr')
-rw-r--r-- | librpc/ndr/ndr_spoolss_buf.c | 65 | ||||
-rw-r--r-- | librpc/ndr/ndr_spoolss_buf.h | 3 |
2 files changed, 0 insertions, 68 deletions
diff --git a/librpc/ndr/ndr_spoolss_buf.c b/librpc/ndr/ndr_spoolss_buf.c index 84d430534f..853d9aaac6 100644 --- a/librpc/ndr/ndr_spoolss_buf.c +++ b/librpc/ndr/ndr_spoolss_buf.c @@ -855,71 +855,6 @@ _PUBLIC_ size_t ndr_size_spoolss_StringArray(const struct spoolss_StringArray *r return ndr_size_struct(r, flags, (ndr_push_flags_fn_t)ndr_push_spoolss_StringArray, ic); } -_PUBLIC_ enum ndr_err_code ndr_push_spoolss_StringArray2(struct ndr_push *ndr, int ndr_flags, const struct spoolss_StringArray2 *r) -{ - if (ndr_flags & NDR_SCALARS) { - uint32_t _ndr_size; - _ndr_size = ndr_size_spoolss_StringArray2(r, ndr->iconv_convenience, ndr->flags); - NDR_CHECK(ndr_push_align(ndr, 4)); - NDR_CHECK(ndr_push_uint32(ndr, NDR_SCALARS, _ndr_size)); - if (_ndr_size > 0) { - uint32_t _flags_save_string_array = ndr->flags; - ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM); - { - struct ndr_push *_ndr_string; - NDR_CHECK(ndr_push_subcontext_start(ndr, &_ndr_string, 0, _ndr_size * 2)); - NDR_CHECK(ndr_push_string_array(_ndr_string, NDR_SCALARS, r->string)); - NDR_CHECK(ndr_push_subcontext_end(ndr, _ndr_string, 0, _ndr_size * 2)); - } - ndr->flags = _flags_save_string_array; - } - NDR_CHECK(ndr_push_trailer_align(ndr, 4)); - } - if (ndr_flags & NDR_BUFFERS) { - } - return NDR_ERR_SUCCESS; -} - -_PUBLIC_ size_t ndr_size_spoolss_StringArray2(const struct spoolss_StringArray2 *r, struct smb_iconv_convenience *ic, int flags) -{ - uint32_t i; - - if (!r || !r->string) { - return 0; - } - - for (i=0; r->string[i]; i++) { - ;; - } - - return (ndr_size_string_array(r->string, i, LIBNDR_FLAG_STR_NULLTERM) + 1); -} - -_PUBLIC_ enum ndr_err_code ndr_pull_spoolss_StringArray2(struct ndr_pull *ndr, int ndr_flags, struct spoolss_StringArray2 *r) -{ - if (ndr_flags & NDR_SCALARS) { - NDR_CHECK(ndr_pull_align(ndr, 4)); - NDR_CHECK(ndr_pull_uint32(ndr, NDR_SCALARS, &r->_ndr_size)); - if (r->_ndr_size) { - uint32_t _flags_save_string_array = ndr->flags; - ndr_set_flags(&ndr->flags, LIBNDR_FLAG_STR_NULLTERM); - { - struct ndr_pull *_ndr_string; - NDR_CHECK(ndr_pull_subcontext_start(ndr, &_ndr_string, 0, r->_ndr_size * 2)); - NDR_CHECK(ndr_pull_string_array(_ndr_string, NDR_SCALARS, &r->string)); - NDR_CHECK(ndr_pull_subcontext_end(ndr, _ndr_string, 0, r->_ndr_size * 2)); - } - ndr->flags = _flags_save_string_array; - } else { - r->string = NULL; - } - NDR_CHECK(ndr_pull_trailer_align(ndr, 4)); - } - if (ndr_flags & NDR_BUFFERS) { - } - return NDR_ERR_SUCCESS; -} - /* hand marshall as pidl cannot (yet) generate a relative pointer to a fixed array of * structs */ diff --git a/librpc/ndr/ndr_spoolss_buf.h b/librpc/ndr/ndr_spoolss_buf.h index 478931e1f8..c0c553b241 100644 --- a/librpc/ndr/ndr_spoolss_buf.h +++ b/librpc/ndr/ndr_spoolss_buf.h @@ -50,9 +50,6 @@ enum ndr_err_code ndr_pull_spoolss_GetPrinterDataEx(struct ndr_pull *ndr, int fl enum ndr_err_code ndr_push_spoolss_SetPrinterDataEx(struct ndr_push *ndr, int flags, const struct spoolss_SetPrinterDataEx *r); uint32_t _ndr_size_spoolss_DeviceMode(struct spoolss_DeviceMode *devmode, struct smb_iconv_convenience *ic, uint32_t flags); size_t ndr_size_spoolss_StringArray(const struct spoolss_StringArray *r, struct smb_iconv_convenience *ic, int flags); -enum ndr_err_code ndr_push_spoolss_StringArray2(struct ndr_push *ndr, int ndr_flags, const struct spoolss_StringArray2 *r); -enum ndr_err_code ndr_pull_spoolss_StringArray2(struct ndr_pull *ndr, int ndr_flags, struct spoolss_StringArray2 *r); -size_t ndr_size_spoolss_StringArray2(const struct spoolss_StringArray2 *r, struct smb_iconv_convenience *ic, int flags); _PUBLIC_ enum ndr_err_code ndr_push_spoolss_DriverInfo101(struct ndr_push *ndr, int ndr_flags, const struct spoolss_DriverInfo101 *r); _PUBLIC_ enum ndr_err_code ndr_pull_spoolss_DriverInfo101(struct ndr_pull *ndr, int ndr_flags, struct spoolss_DriverInfo101 *r); void ndr_print_spoolss_Field(struct ndr_print *ndr, const char *name, const union spoolss_Field *r); |