From f989c36a523740f3ce7fe2dfee38e6e423f9ac8b Mon Sep 17 00:00:00 2001 From: Rich Megginson <rmeggins@xxxxxxxxxx> Date: Wed, 10 Aug 2011 14:56:54 -0600 Subject: [PATCH] make sure the DBVERSION file ends in a newline --- ldap/servers/slapd/back-ldbm/dbversion.c | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/ldap/servers/slapd/back-ldbm/dbversion.c b/ldap/servers/slapd/back-ldbm/dbversion.c index 5c5cdeb..4c47c3d 100644 --- a/ldap/servers/slapd/back-ldbm/dbversion.c +++ b/ldap/servers/slapd/back-ldbm/dbversion.c @@ -122,7 +122,9 @@ dbversion_write(struct ldbminfo *li, const char *directory, len = strlen(buf); ptr = buf + len; } - len = strlen( buf ); + /* end in a newline */ + PL_strncpyz(ptr, "\n", sizeof(buf) - len); + len = strlen(buf); if ( slapi_write_buffer( prfd, buf, len ) != len ) { LDAPDebug( LDAP_DEBUG_ANY, "Could not write to file \"%s\"\n", filename, 0, 0 ); -- 1.7.1
-- 389-devel mailing list 389-devel@xxxxxxxxxxxxxxxxxxxxxxx https://admin.fedoraproject.org/mailman/listinfo/389-devel