Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(13)

Unified Diff: impl/memory/datastore_data.go

Issue 1309803004: Add transaction buffer filter. (Closed) Base URL: https://github.com/luci/gae.git@add_query_support
Patch Set: Make tests faster, no lock for queries Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « filter/txnBuf/txnbuf_test.go ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: impl/memory/datastore_data.go
diff --git a/impl/memory/datastore_data.go b/impl/memory/datastore_data.go
index e221c55eee161eb9fda8fece355a4a71da1da546..f0dcc416b9f14ed55711304ee82a1a4dcf6cd6a3 100644
--- a/impl/memory/datastore_data.go
+++ b/impl/memory/datastore_data.go
@@ -126,7 +126,8 @@ func (d *dataStoreData) getQuerySnaps(consistent bool) (idx, head *memStore) {
defer d.rwlock.RUnlock()
if d.snap == nil {
// we're 'always consistent'
- return d.head, d.head
+ snap := d.head.Snapshot()
+ return snap, snap
iannucci 2015/09/30 03:03:31 This was really dumb on my part. `d.head` is the c
}
head = d.head.Snapshot()
« no previous file with comments | « filter/txnBuf/txnbuf_test.go ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698