From 551532d007970ab11dca71b532754728a6a78496 Mon Sep 17 00:00:00 2001 From: xzhao9 Date: Sun, 3 Jan 2021 13:02:18 -0500 Subject: [PATCH] s3:registry Renaming get_charset() to smbreg_get_charset() Rename to smbreg_get_charset() function to avoid naming conflict with MariaDB. Signed-off-by: xzhao9 Reviewed-by: Jeremy Allison Reviewed-by: David Mulder Autobuild-User(master): Jeremy Allison Autobuild-Date(master): Wed Feb 10 21:00:28 UTC 2021 on sn-devel-184 --- source3/registry/reg_format.c | 2 +- source3/registry/reg_parse_internal.c | 6 +++--- source3/registry/reg_parse_internal.h | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/source3/registry/reg_format.c b/source3/registry/reg_format.c index 36ccb626194..b95f87c2a70 100644 --- a/source3/registry/reg_format.c +++ b/source3/registry/reg_format.c @@ -791,7 +791,7 @@ struct reg_format* reg_format_file(const void* talloc_ctx, opt.enc)); goto fail; } - fmt_ctx->encoding = talloc_strdup(fmt_ctx, get_charset(opt.enc)); + fmt_ctx->encoding = talloc_strdup(fmt_ctx, smbreg_get_charset(opt.enc)); fmt_ctx->file = fopen(filename, "w"); if (fmt_ctx->file == NULL) { diff --git a/source3/registry/reg_parse_internal.c b/source3/registry/reg_parse_internal.c index 8f0ab92b315..d68fee6d9fc 100644 --- a/source3/registry/reg_parse_internal.c +++ b/source3/registry/reg_parse_internal.c @@ -215,7 +215,7 @@ const struct hive_info* hive_info(const char* name) return info; } -const char* get_charset(const char* c) +const char *smbreg_get_charset(const char *c) { if (strcmp(c, "dos") == 0) { return lp_dos_charset(); @@ -231,8 +231,8 @@ bool set_iconv(smb_iconv_t* t, const char* to, const char* from) smb_iconv_t cd = (smb_iconv_t)-1; if (to && from) { - to = get_charset(to); - from = get_charset(from); + to = smbreg_get_charset(to); + from = smbreg_get_charset(from); cd = smb_iconv_open(to, from); if (cd == ((smb_iconv_t)-1)) { return false; diff --git a/source3/registry/reg_parse_internal.h b/source3/registry/reg_parse_internal.h index 1440d5549f9..c2e4c8db60f 100644 --- a/source3/registry/reg_parse_internal.h +++ b/source3/registry/reg_parse_internal.h @@ -73,7 +73,7 @@ bool srprs_hive(const char** ptr, const struct hive_info** result); -const char* get_charset(const char* c); +const char *smbreg_get_charset(const char *c); bool set_iconv(smb_iconv_t* t, const char* to, const char* from); -- 2.11.4.GIT