[SCM] Samba Shared Repository - branch v3-3-test updated - release-3-2-0pre2-4999-g07c7085

Derrell Lipman derrell.lipman at unwireduniverse.com
Fri Feb 20 19:48:10 MST 2009


On Fri, Feb 20, 2009 at 7:41 PM, Jeremy Allison <jra at samba.org> wrote:

>
> -       smbc_set_credentials(workgroup,
> -                            user,
> -                            password,
> +       /* Using CONST_DISCARD here is ugly, but
> +        * we know that smbc_set_credentials() doesn't
> +        * actually modify the strings, and should have
> +        * been const from the start. We're constrained
> +        * by the ABI here.
> +        */
> +
> +       smbc_set_credentials(CONST_DISCARD(char *,workgroup),
> +                            CONST_DISCARD(char *,user),
> +                            CONST_DISCARD(char *,password),
>                             use_kerberos,
> -                            (char *)signing_state);
> +                            CONST_DISCARD(char *,signing_state));
>
>
Jeremy, this is fugly. Would you please either convince me that changing
smbc_set_credentials to have const parameters would, in fact, change the ABI
(it is my contention that it does not), or let's remove this crap and add
const to the smbc_set_credentials parameters.

Thanks.

Derrell


More information about the samba-technical mailing list