[glom] Box_DataDetails::fill_from_database(): Correctly find the primary key.
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [glom] Box_DataDetails::fill_from_database(): Correctly find the primary key.
- Date: Thu, 28 Jan 2016 22:31:51 +0000 (UTC)
commit 247442e6ea7eaf6c29a78720cdd1799569e4eacd
Author: Murray Cumming <murrayc murrayc com>
Date: Wed Jan 27 11:01:51 2016 +0100
Box_DataDetails::fill_from_database(): Correctly find the primary key.
This was a regression caused by use of auto in this commit:
https://git.gnome.org/browse/glom/commit/glom/mode_data/box_data_details.cc?id=37a00864fc3fa2f96b75ebb83f97a61628592df2
glom/mode_data/box_data_details.cc | 5 +++--
1 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/glom/mode_data/box_data_details.cc b/glom/mode_data/box_data_details.cc
index 8d632d1..a273b1d 100644
--- a/glom/mode_data/box_data_details.cc
+++ b/glom/mode_data/box_data_details.cc
@@ -327,8 +327,9 @@ bool Box_Data_Details::fill_from_database()
continue;
//Compare the relationship and related relationship:
- auto uses_a = layout_item_pk;
- auto uses_b = element;
+ //Don't use auto here. We need to compare them as UsesRelationship.
+ const std::shared_ptr<const UsesRelationship> uses_a = layout_item_pk;
+ const std::shared_ptr<const UsesRelationship> uses_b = element;
if(*uses_a == *uses_b)
{
index_primary_key = i;
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]