1
0
mirror of https://github.com/samba-team/samba.git synced 2025-03-11 16:58:40 +03:00

s3-spoolss: Added more winreg hepler functions.

Signed-off-by: Günther Deschner <gd@samba.org>
This commit is contained in:
Andreas Schneider 2010-04-21 18:12:50 +02:00 committed by Günther Deschner
parent d4f563d9d4
commit b33e877aad

View File

@ -1058,6 +1058,26 @@ static WERROR winreg_enumval_to_multi_sz(TALLOC_CTX *mem_ctx,
return WERR_OK;
}
static WERROR winreg_enumval_to_blob(TALLOC_CTX *mem_ctx,
struct spoolss_PrinterEnumValues *v,
const char *valuename,
DATA_BLOB *blob)
{
/* just return if it is not the one we are looking for */
if (strcmp(valuename, v->value_name) != 0) {
return WERR_NOT_FOUND;
}
if (v->type != REG_BINARY) {
return WERR_INVALID_DATATYPE;
}
blob->data = v->data->data;
blob->length = v->data_length;
return WERR_OK;
}
/********************************************************************
Public winreg function for spoolss
********************************************************************/