From: Kurt Zeilenga Date: Mon, 5 Aug 2002 19:43:01 +0000 (+0000) Subject: Set O_EXCL (ITS#2009) X-Git-Tag: NO_SLAP_OP_BLOCKS~1287 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=c673b651e8f3643e7382e58fd596f88e5115f889;p=openldap Set O_EXCL (ITS#2009) --- diff --git a/servers/slurpd/reject.c b/servers/slurpd/reject.c index 91e1c6a11e..2596ab57bc 100644 --- a/servers/slurpd/reject.c +++ b/servers/slurpd/reject.c @@ -63,7 +63,7 @@ write_reject( if ( access( rejfile, F_OK ) < 0 ) { /* Doesn't exist - try to create */ int rjfd; - if (( rjfd = open( rejfile, O_RDWR | O_APPEND | O_CREAT, + if (( rjfd = open( rejfile, O_RDWR|O_APPEND|O_CREAT|O_EXCL, S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP )) < 0 ) { #ifdef NEW_LOGGING LDAP_LOG ( SLURPD, ERR, "write_reject: "