Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:12.2
rpm-python
dbrointerruptable.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File dbrointerruptable.diff of Package rpm-python
--- ./lib/rpmdb.c.orig 2011-09-19 10:02:08.000000000 +0000 +++ ./lib/rpmdb.c 2011-10-19 15:06:25.000000000 +0000 @@ -630,10 +630,12 @@ int rpmdbClose(rpmdb db) { rpmdb * prev, next; int rc = 0; + int dbmode; if (db == NULL) goto exit; + dbmode = db->db_mode; (void) rpmdbUnlink(db); if (db->nrefs > 0) @@ -661,7 +663,7 @@ int rpmdbClose(rpmdb db) db = _free(db); - if (rpmdbRock == NULL) { + if (rpmdbRock == NULL && (dbmode & (O_RDWR|O_WRONLY)) != 0) { (void) rpmsqEnable(-SIGHUP, NULL); (void) rpmsqEnable(-SIGINT, NULL); (void) rpmsqEnable(-SIGTERM, NULL); @@ -730,7 +732,7 @@ static int openDatabase(const char * pre /* Try to ensure db home exists, error out if we cant even create */ rc = rpmioMkpath(rpmdbHome(db), 0755, getuid(), getgid()); if (rc == 0) { - if (rpmdbRock == NULL) { + if (rpmdbRock == NULL && (db->db_mode & (O_RDWR|O_WRONLY)) != 0) { (void) rpmsqEnable(SIGHUP, NULL); (void) rpmsqEnable(SIGINT, NULL); (void) rpmsqEnable(SIGTERM, NULL);
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor