Skip to content

Fix several YapDatabaseRelationship extension bugs#399

Closed
JimRoepcke wants to merge 5 commits into
yapstudios:masterfrom
JimRoepcke:master
Closed

Fix several YapDatabaseRelationship extension bugs#399
JimRoepcke wants to merge 5 commits into
yapstudios:masterfrom
JimRoepcke:master

Conversation

@JimRoepcke
Copy link
Copy Markdown
Contributor

The edgeCache was getting corrupted by some incorrect SQLite column offsets, which was resulting in edges being returned with invalid destination and delete rules.

Also, when deleting edges that were just added, the NotInDatabase flag wasn't being set in all cases leading to an assertion in -deleteEdge: failing. Note that this commit only addresses this issue for manual edges - I'm not using protocol edges and didn't feel comfortable modifying the code in the preprocessProtocolEdges method yet.

This includes a commit from the 3.0 branch that fixes a minor bug

if (!(edge->state & YDB_EdgeState_HasEdgeRowid))
{
edge->flags |= YDB_EdgeFlags_EdgeNotInDatabase;
}
Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Throughout this file, it looks like the additions are indented with spaces, but the existing code uses tabs.

@robbiehanson
Copy link
Copy Markdown
Contributor

Thank you! Merged into "v3.0" branch.

robbiehanson added a commit that referenced this pull request Mar 8, 2018
…otocolEdges instead of manualEdges. Added corresponding unit test as well.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants