]> git.sur5r.net Git - openldap/blobdiff - libraries/libldap/getfilter.c
Cast char* argument to hh_to_c() to Byte*
[openldap] / libraries / libldap / getfilter.c
index a33e2ca7cebd11bf4f28ce9590acb18232aed38f..d69ff0e9e881f17e3c1443a87c2105dbe9d6c583 100644 (file)
@@ -122,7 +122,7 @@ ldap_init_getfilter_buf( char *buf, long buflen )
                char error[512];
                regerror(rc, &re, error, sizeof(error));
                ldap_getfilter_free( lfdp );
-               fprintf( stderr, "bad regular expresssion %s, %s\n",
+               fprintf( stderr, "bad regular expression %s, %s\n",
                        nextflp->lfl_pattern, error );
                errno = EINVAL;
 #endif /* LDAP_LIBUI */
@@ -331,12 +331,12 @@ ldap_build_filter( char *filtbuf, unsigned long buflen, char *pattern,
            if ( *p == '%' ) {
                ++p;
                if ( *p == 'v' ) {
-                   if ( isdigit( *(p+1))) {
+                   if ( isdigit( (unsigned char) p[1] )) {
                        ++p;
                        wordnum = *p - '1';
                        if ( *(p+1) == '-' ) {
                            ++p;
-                           if ( isdigit( *(p+1))) {
+                           if ( isdigit( (unsigned char) p[1] )) {
                                ++p;
                                endwordnum = *p - '1';  /* e.g., "%v2-4" */
                                if ( endwordnum > wordcount - 1 ) {