X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=libraries%2Flibldap%2Ft61.c;h=199a908ab2e7bd865c682123fb2620cc0fb1486b;hb=de01a6e3d791d3458549d2ceeccf4d7e0477ff78;hp=4450e2d3ba7ea9722b7260f80b60ad5e7803a959;hpb=6939c531700652491f4be4688c6a1f35a1ab8a18;p=openldap diff --git a/libraries/libldap/t61.c b/libraries/libldap/t61.c index 4450e2d3ba..199a908ab2 100644 --- a/libraries/libldap/t61.c +++ b/libraries/libldap/t61.c @@ -1,7 +1,20 @@ /* $OpenLDAP$ */ -/* - * Copyright 2002-2003 The OpenLDAP Foundation, All Rights Reserved. - * COPYING RESTRICTIONS APPLY, see COPYRIGHT file +/* This work is part of OpenLDAP Software . + * + * Copyright 2002-2007 The OpenLDAP Foundation. + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted only as authorized by the OpenLDAP + * Public License. + * + * A copy of this license is available in the file LICENSE in the + * top-level directory of the distribution or, alternatively, at + * . + */ +/* ACKNOWLEDGEMENTS: + * This work was initially developed by Howard Chu for inclusion in + * OpenLDAP Software. */ /* @@ -332,7 +345,7 @@ int ldap_t61s_to_utf8s( struct berval *src, struct berval *dst ) /* Invalid T.61 characters? */ if (!t61_tab[*c]) return LDAP_INVALID_SYNTAX; - if (*c & 0xf0 == 0xc0) { + if ((*c & 0xf0) == 0xc0) { int j = *c & 0x0f; /* If this is the end of the string, or if the base * character is just a space, treat this as a regular @@ -368,7 +381,7 @@ int ldap_t61s_to_utf8s( struct berval *src, struct berval *dst ) return LDAP_NO_MEMORY; for (i=0,c=(unsigned char *)src->bv_val; i < src->bv_len; c++,i++) { - if (*c & 0xf0 == 0xc0) { + if ((*c & 0xf0) == 0xc0) { int j = *c & 0x0f; /* If this is the end of the string, or if the base * character is just a space, treat this as a regular