[glom] DbUtils::recreate_database_from_document(): Set table privileges too.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glom] DbUtils::recreate_database_from_document(): Set table privileges too.
- Date: Fri, 2 Dec 2011 15:45:17 +0000 (UTC)
commit 578cd716df4953d6e111e4d62c65e69f8497f061
Author: Murray Cumming <murrayc murrayc com>
Date: Fri Dec 2 16:44:31 2011 +0100
DbUtils::recreate_database_from_document(): Set table privileges too.
* glom/libglom/db_utils.cc: recreate_database_from_document():
Also call set_table_privileges_groups_from_document().
ChangeLog | 7 +++++++
glom/libglom/db_utils.cc | 8 ++++++++
2 files changed, 15 insertions(+), 0 deletions(-)
---
diff --git a/ChangeLog b/ChangeLog
index 7bb0444..f033354 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,12 @@
2011-12-02 Murray Cumming <murrayc murrayc com>
+ DbUtils::recreate_database_from_document(): Set table privileges too.
+
+ * glom/libglom/db_utils.cc: recreate_database_from_document():
+ Also call set_table_privileges_groups_from_document().
+
+2011-12-02 Murray Cumming <murrayc murrayc com>
+
DbUtils::recreate_database_from_document(): Create groups too.
* glom/libglom/db_utils.[h|cc]: recreate_database_from_document():
diff --git a/glom/libglom/db_utils.cc b/glom/libglom/db_utils.cc
index 21339bb..d8bdbab 100644
--- a/glom/libglom/db_utils.cc
+++ b/glom/libglom/db_utils.cc
@@ -286,6 +286,14 @@ bool recreate_database_from_document(Document* document, const sigc::slot<void>&
std::cerr << G_STRFUNC << ": add_groups_from_document() failed." << std::endl;
return false;
}
+
+ //Set table privileges, using the groups we just added:
+ progress();
+ if(!DbUtils::set_table_privileges_groups_from_document(document))
+ {
+ std::cerr << G_STRFUNC << ": set_table_privileges_groups_from_document() failed." << std::endl;
+ return false;
+ }
for(Document::type_listTableInfo::const_iterator iter = tables.begin(); iter != tables.end(); ++iter)
{
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]