[vlendec at samba.org: [SCM] Samba Shared Repository - branch master updated]

Matthieu Patou mat at samba.org
Tue Mar 29 12:07:22 MDT 2011


On 29/03/2011 21:37, Volker Lendecke wrote:
> Hi, Tridge!
>
> Can you please put in an autotest for non-ascii character
> conversion so that this does not happen again?
>
Why in autotest ? why not in make test  (so that if someone broke it, 
it's notice it without needing autobuild).

Matthieu
> Thanks,
>
> Volker
>
> ----- Forwarded message from Volker Lendecke<vlendec at samba.org>  -----
>
> Date: Tue, 29 Mar 2011 19:18:01 +0200 (CEST)
> From: Volker Lendecke<vlendec at samba.org>
> To: samba-cvs at samba.org
> Subject: [SCM] Samba Shared Repository - branch master updated
>
> The branch, master has been updated
>         via  1e50f9a charconv: Fix the slow-path character conversions
>        from  52ff0dd s3-libsmb: remove duplicate NTSTATUS variable.
>
> http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
>
>
> - Log -----------------------------------------------------------------
> commit 1e50f9a5c263ed19ef8e9c689c96f1e51194f405
> Author: Volker Lendecke<vl at samba.org>
> Date:   Tue Mar 29 18:22:18 2011 +0200
>
>      charconv: Fix the slow-path character conversions
>
>      This reverts a part of 0189087e257f. That one might have fixed the fast path,
>      but it broke the slow path. convert_string_internal returns 0/-1 despite the
>      size_t result type and the misleading comment. If you follow the path to
>      smb_iconv and for example iconv_copy(), you will see that this routine returns
>      0 even after it copied something.
>
>      How to check: Use German locale, and do an smbclient "allinfo" on a file
>      modified in march (März in German). Notice the "ä". Before 0189087 this printed
>      correctly, after 0189087 it cut off the fields after the M for März.
>
>      Autobuild-User: Volker Lendecke<vlendec at samba.org>
>      Autobuild-Date: Tue Mar 29 19:17:41 CEST 2011 on sn-devel-104
>
> -----------------------------------------------------------------------
>
> Summary of changes:
>   source3/lib/charcnv.c |    6 +++---
>   1 files changed, 3 insertions(+), 3 deletions(-)
>
>
> Changeset truncated at 500 lines:
>
> diff --git a/source3/lib/charcnv.c b/source3/lib/charcnv.c
> index f95442a..77e359d 100644
> --- a/source3/lib/charcnv.c
> +++ b/source3/lib/charcnv.c
> @@ -187,7 +187,7 @@ size_t convert_string_error(charset_t from, charset_t to,
>   #else
>   				size_t ret = convert_string_internal(from, to, p, slen, q, dlen, converted_size);
>   				if (converted_size) {
> -					*converted_size = ret + retval;
> +					*converted_size += retval;
>   				}
>   				return ret;
>   #endif
> @@ -231,7 +231,7 @@ size_t convert_string_error(charset_t from, charset_t to,
>   #else
>   				size_t ret = convert_string_internal(from, to, p, slen, q, dlen, converted_size);
>   				if (converted_size) {
> -					*converted_size = ret + retval;
> +					*converted_size += retval;
>   				}
>   				return ret;
>   #endif
> @@ -275,7 +275,7 @@ size_t convert_string_error(charset_t from, charset_t to,
>   #else
>   				size_t ret = convert_string_internal(from, to, p, slen, q, dlen, converted_size);
>   				if (converted_size) {
> -					*converted_size = ret + retval;
> +					*converted_size += retval;
>   				}
>   				return ret;
>   #endif
>
>


-- 
Matthieu Patou
Samba Team        http://samba.org
Private repo      http://git.samba.org/?p=mat/samba.git;a=summary




More information about the samba-technical mailing list