From: Mark Eichin Date: Tue, 30 Jan 1996 23:28:18 +0000 (+0000) Subject: * kdb_dbm.c (krb5_dbm_db_rename): O_EXCL is meaningless without X-Git-Tag: krb5-1.0-beta6~540 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=ec652e09abfad367adcefb4ddd117e80f4927ae3;p=krb5.git * kdb_dbm.c (krb5_dbm_db_rename): O_EXCL is meaningless without O_CREAT. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7416 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/kdb/ChangeLog b/src/lib/kdb/ChangeLog index 34e37e063..d6609bc0c 100644 --- a/src/lib/kdb/ChangeLog +++ b/src/lib/kdb/ChangeLog @@ -1,3 +1,8 @@ +Tue Jan 30 18:26:38 1996 Mark Eichin + + * kdb_dbm.c (krb5_dbm_db_rename): O_EXCL is meaningless without + O_CREAT. + Sat Jan 27 01:01:17 1996 Mark Eichin * t_kdb.c: wrap db_dbm decls and berkely_dispatch in ifdefs diff --git a/src/lib/kdb/kdb_dbm.c b/src/lib/kdb/kdb_dbm.c index 989a19ba1..1d61c622f 100644 --- a/src/lib/kdb/kdb_dbm.c +++ b/src/lib/kdb/kdb_dbm.c @@ -895,7 +895,7 @@ krb5_dbm_db_rename(context, from, to) if ((db_ctx->db_lf_name = gen_dbsuffix(db_ctx->db_name, KDBM_LOCK_EXT(db_ctx)))) { if ((db_ctx->db_lf_file = open(db_ctx->db_lf_name, - O_RDWR|O_EXCL, 0600)) >= 0){ + O_RDWR|O_EXCL|O_CREAT, 0600)) >= 0){ db_ctx->db_inited = 1; if ((retval = krb5_dbm_db_get_age(context, NULL,