Since it's introduction, rpmtsInitDB() has passed the second argument 
directly to rpmdbInit() as permission bits. However commit 
81fef9848051e5068694cde9b3c2be743d5a93e1 incorrectly documented this as being 
related to the db mode read/write *mode*, and also used it that way in the 
python bindings.

While looking at this, noticed that ndb passes hardcoded 0666 to open() whereas 
the rpm default open mode is 0644, use the API-requested mode instead. Sqlite 
doesn't seem to support passing a file mode request in the API (but it 
defaults to 0644 too).
You can view, comment on, or merge this pull request online at:

  https://github.com/rpm-software-management/rpm/pull/1525

-- Commit Summary --

  * Fix rpmtsInitDB() argument confusion
  * Honor requested file permissions when creating ndb database files

-- File Changes --

    M lib/backend/ndb/glue.c (10)
    M lib/rpmts.c (4)
    M lib/rpmts.h (5)
    M python/rpmts-py.c (2)

-- Patch Links --

https://github.com/rpm-software-management/rpm/pull/1525.patch
https://github.com/rpm-software-management/rpm/pull/1525.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/pull/1525
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to