]> git.sur5r.net Git - openldap/commitdiff
printf format paranoia: macros could be changed to contain format chars
authorHallvard Furuseth <hallvard@openldap.org>
Fri, 18 May 2007 14:48:28 +0000 (14:48 +0000)
committerHallvard Furuseth <hallvard@openldap.org>
Fri, 18 May 2007 14:48:28 +0000 (14:48 +0000)
servers/slapd/back-bdb/dbcache.c
servers/slapd/sasl.c

index 42f9f8b88320a495dc2ed2d683a8c2cbc982b3d5..35529c79231b31e5d29c047cae8f103a2b0624cb 100644 (file)
@@ -114,7 +114,7 @@ bdb_db_cache(
        rc = db->bdi_db->set_flags( db->bdi_db, DB_DUP | DB_DUPSORT );
 
        file = ch_malloc( strlen( name ) + sizeof(BDB_SUFFIX) );
-       sprintf( file, "%s" BDB_SUFFIX, name );
+       sprintf( file, "%s%s", name, BDB_SUFFIX );
 
 #ifdef HAVE_EBCDIC
        __atoe( file );
index cf952291bfcb573790dc0efcc5687687e0f6935e..e08400462fff20756c570216575938792c46574c 100644 (file)
@@ -1210,8 +1210,8 @@ int slap_sasl_init( void )
                sprintf( version, "%u.%d.%d", (unsigned)rc >> 24, (rc >> 16) & 0xff,
                        rc & 0xffff );
                Debug( LDAP_DEBUG_ANY, "slap_sasl_init: SASL library version mismatch:"
-                       " expected " SASL_VERSION_STRING ","
-                       " got %s\n", version, 0, 0 );
+                       " expected %s, got %s\n",
+                       SASL_VERSION_STRING, version, 0 );
                return -1;
        }
 #endif