mirror of
https://github.com/FirebirdSQL/firebird.git
synced 2025-01-23 22:03:03 +01:00
Frontported fix for CORE-2221: Attach to any DB fails after modification of access rights of security2.fdb
This commit is contained in:
parent
43456bd96b
commit
15800b90b9
@ -411,7 +411,7 @@ namespace {
|
|||||||
// may be some old data about really active semaphore sets?
|
// may be some old data about really active semaphore sets?
|
||||||
if (version == CURRENT_VERSION)
|
if (version == CURRENT_VERSION)
|
||||||
{
|
{
|
||||||
int semId = semget(set[i].semKey, SEM_PER_SET, PRIV);
|
int semId = semget(set[i].semKey, SEM_PER_SET, 0);
|
||||||
if (semId > 0)
|
if (semId > 0)
|
||||||
{
|
{
|
||||||
semctl(semId, 0, IPC_RMID);
|
semctl(semId, 0, IPC_RMID);
|
||||||
@ -4039,7 +4039,7 @@ static SLONG create_semaphores(
|
|||||||
while (true)
|
while (true)
|
||||||
{
|
{
|
||||||
// Try to open existing semaphore set
|
// Try to open existing semaphore set
|
||||||
semid = semget(key, 0, PRIV);
|
semid = semget(key, 0, 0);
|
||||||
if (semid == -1) {
|
if (semid == -1) {
|
||||||
if (errno != ENOENT) {
|
if (errno != ENOENT) {
|
||||||
error(status_vector, "semget", errno);
|
error(status_vector, "semget", errno);
|
||||||
|
Loading…
Reference in New Issue
Block a user