diff options
author | Andrew Bartlett <abartlet@samba.org> | 2011-02-18 10:24:58 +1100 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-02-18 18:41:00 +1100 |
commit | 8afc271e2a9950fda68e99928746623093cbd6ac (patch) | |
tree | e2a685a3929cea74a5d1b7f09ca6508e2b60fa30 /source3/modules | |
parent | bed374215ff040cc995659d42938be35412a794a (diff) | |
download | samba-8afc271e2a9950fda68e99928746623093cbd6ac.tar.gz samba-8afc271e2a9950fda68e99928746623093cbd6ac.tar.xz samba-8afc271e2a9950fda68e99928746623093cbd6ac.zip |
lib/util/charset Use top level iconv.c in source3
The two files were very similar already, the only change required was
to adopt the s3 module registration fucntion name.
(NTSTATUS wasn't used as the charset code does not otherwise use that
type).
Andrew Bartlett
Signed-off-by: Andrew Tridgell <tridge@samba.org>
Diffstat (limited to 'source3/modules')
-rw-r--r-- | source3/modules/charset_macosxfs.c | 5 | ||||
-rw-r--r-- | source3/modules/developer.c | 8 | ||||
-rw-r--r-- | source3/modules/weird.c | 5 |
3 files changed, 13 insertions, 5 deletions
diff --git a/source3/modules/charset_macosxfs.c b/source3/modules/charset_macosxfs.c index baf2a0071cb..8c2fdc7776b 100644 --- a/source3/modules/charset_macosxfs.c +++ b/source3/modules/charset_macosxfs.c @@ -595,7 +595,10 @@ static struct charset_functions macosxfs_encoding_functions = { NTSTATUS charset_macosxfs_init(void) { - return smb_register_charset(&macosxfs_encoding_functions); + if (!smb_register_charset(&macosxfs_encoding_functions)) { + return NT_STATUS_INTERNAL_ERROR; + } + return NT_STATUS_OK; } /* eof */ diff --git a/source3/modules/developer.c b/source3/modules/developer.c index 37019256db8..42471e2d33e 100644 --- a/source3/modules/developer.c +++ b/source3/modules/developer.c @@ -124,8 +124,10 @@ static size_t weird_push(void *cd, char **inbuf, size_t *inbytesleft, struct charset_functions weird_functions = {"WEIRD", weird_pull, weird_push}; -int charset_weird_init(void) +NTSTATUS charset_weird_init(void) { - smb_register_charset(&weird_functions); - return True; + if (!smb_register_charset(&weird_functions)) { + return NT_STATUS_INTERNAL_ERROR; + } + return NT_STATUS_OK; } diff --git a/source3/modules/weird.c b/source3/modules/weird.c index eab17ce50e8..5db8cdcecd1 100644 --- a/source3/modules/weird.c +++ b/source3/modules/weird.c @@ -127,5 +127,8 @@ struct charset_functions weird_functions = {"WEIRD", weird_pull, weird_push}; NTSTATUS charset_weird_init(void); NTSTATUS charset_weird_init(void) { - return smb_register_charset(&weird_functions); + if (!smb_register_charset(&weird_functions)) { + return NT_STATUS_INTERNAL_ERROR; + } + return NT_STATUS_OK; } |