]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/passwd.c
Experimental code that uses one locker ID per thread. Seems to work OK,
[openldap] / servers / slapd / passwd.c
index 06cc1586a87478d2285866f4d7b2badd4b3d0bf0..f45b974272d4bb57a657a29aea2d56f4c2313c0f 100644 (file)
@@ -119,8 +119,8 @@ int slap_passwd_parse( struct berval *reqdata,
        if( tag == LDAP_TAG_EXOP_MODIFY_PASSWD_ID ) {
                if( id == NULL ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse: ID not allowed.\n"));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse: ID not allowed.\n", 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: ID not allowed.\n",
                                0, 0, 0 );
@@ -135,8 +135,8 @@ int slap_passwd_parse( struct berval *reqdata,
 
                if( tag == LBER_ERROR ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse:  ID parse failed.\n"));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse:  ID parse failed.\n", 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: ID parse failed.\n",
                                0, 0, 0 );
@@ -151,8 +151,8 @@ int slap_passwd_parse( struct berval *reqdata,
        if( tag == LDAP_TAG_EXOP_MODIFY_PASSWD_OLD ) {
                if( oldpass == NULL ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse: OLD not allowed.\n" ));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse: OLD not allowed.\n" , 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: OLD not allowed.\n",
                                0, 0, 0 );
@@ -167,8 +167,8 @@ int slap_passwd_parse( struct berval *reqdata,
 
                if( tag == LBER_ERROR ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse:  ID parse failed.\n" ));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse:  ID parse failed.\n" , 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: ID parse failed.\n",
                                0, 0, 0 );
@@ -183,8 +183,8 @@ int slap_passwd_parse( struct berval *reqdata,
        if( tag == LDAP_TAG_EXOP_MODIFY_PASSWD_NEW ) {
                if( newpass == NULL ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse:  NEW not allowed.\n" ));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse:  NEW not allowed.\n", 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: NEW not allowed.\n",
                                0, 0, 0 );
@@ -199,8 +199,8 @@ int slap_passwd_parse( struct berval *reqdata,
 
                if( tag == LBER_ERROR ) {
 #ifdef NEW_LOGGING
-                       LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                                  "slap_passwd_parse:  OLD parse failed.\n"));
+                       LDAP_LOG( OPERATION, ERR,
+                          "slap_passwd_parse:  OLD parse failed.\n", 0, 0, 0 );
 #else
                        Debug( LDAP_DEBUG_TRACE, "slap_passwd_parse: OLD parse failed.\n",
                                0, 0, 0 );
@@ -215,8 +215,8 @@ int slap_passwd_parse( struct berval *reqdata,
        if( len != 0 ) {
 decoding_error:
 #ifdef NEW_LOGGING
-               LDAP_LOG(( "operation", LDAP_LEVEL_ERR,
-                          "slap_passwd_parse: decoding error, len=%ld\n", (long)len ));
+               LDAP_LOG( OPERATION, ERR, 
+                       "slap_passwd_parse: decoding error, len=%ld\n", (long)len, 0, 0 );
 #else
                Debug( LDAP_DEBUG_TRACE,
                        "slap_passwd_parse: decoding error, len=%ld\n",
@@ -243,8 +243,8 @@ struct berval * slap_passwd_return(
        assert( cred != NULL );
 
 #ifdef NEW_LOGGING
-       LDAP_LOG(( "operation", LDAP_LEVEL_ENTRY,
-                  "slap_passwd_return: %ld\n",(long)cred->bv_len ));
+       LDAP_LOG( OPERATION, ENTRY, 
+               "slap_passwd_return: %ld\n",(long)cred->bv_len, 0, 0 );
 #else
        Debug( LDAP_DEBUG_TRACE, "slap_passwd_return: %ld\n",
                (long) cred->bv_len, 0, 0 );
@@ -302,8 +302,7 @@ slap_passwd_generate( struct berval *pass )
 {
        struct berval *tmp;
 #ifdef NEW_LOGGING
-       LDAP_LOG(( "operation", LDAP_LEVEL_ENTRY,
-                  "slap_passwd_generate: begin\n" ));
+       LDAP_LOG( OPERATION, ENTRY, "slap_passwd_generate: begin\n", 0, 0, 0 );
 #else
        Debug( LDAP_DEBUG_TRACE, "slap_passwd_generate\n", 0, 0, 0 );
 #endif