From: Richard Basch Date: Wed, 6 Mar 1996 21:39:17 +0000 (+0000) Subject: POSIX requires a file be opened read-write for locking X-Git-Tag: krb5-1.0-beta6~403 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=f7644ddb5931db90834832f544fd330eedbd797c;p=krb5.git POSIX requires a file be opened read-write for locking git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@7597 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/admin/edit/dump.c b/src/admin/edit/dump.c index 405074c88..2f6ed577c 100644 --- a/src/admin/edit/dump.c +++ b/src/admin/edit/dump.c @@ -1644,7 +1644,7 @@ load_db(argc, argv) * Open the dumpfile */ if (dumpfile) { - if ((f = fopen(dumpfile, "r"))) { + if ((f = fopen(dumpfile, "r+"))) { kret = krb5_lock_file(kcontext, fileno(f), KRB5_LOCKMODE_SHARED); } }