From 4a25366df4303bebdbd771dcec202e8368fdb61f Mon Sep 17 00:00:00 2001 From: "Brian S. O'Neill" Date: Sat, 25 Jul 2009 17:47:01 +0000 Subject: Make cursors more resilient against concurrent close, preventing NoSuchElementException from being thrown inappropriately. --- src/main/java/com/amazon/carbonado/repo/indexed/IndexedCursor.java | 1 + 1 file changed, 1 insertion(+) (limited to 'src/main/java/com/amazon/carbonado/repo/indexed') diff --git a/src/main/java/com/amazon/carbonado/repo/indexed/IndexedCursor.java b/src/main/java/com/amazon/carbonado/repo/indexed/IndexedCursor.java index de105cc..872b5b4 100644 --- a/src/main/java/com/amazon/carbonado/repo/indexed/IndexedCursor.java +++ b/src/main/java/com/amazon/carbonado/repo/indexed/IndexedCursor.java @@ -152,6 +152,7 @@ class IndexedCursor extends AbstractCursor { } } } + } catch (NoSuchElementException e) { } catch (FetchException e) { try { close(); -- cgit v1.2.3