This is an automated email from the ASF dual-hosted git repository.
nightowl888 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/lucenenet.git
The following commit(s) were added to refs/heads/master by this push:
new d29d0e5 Lucene.Net.Search.Join.ToParentBlockJoinCollector: Fixed
nullable conversion issue - null was converted to -1 in Java, so we must use -1
when the item is not in the collection
d29d0e5 is described below
commit d29d0e50a922ea0b049f2ce23f813c5b4e5f9b0c
Author: Shad Storhaug <[email protected]>
AuthorDate: Mon Dec 13 19:18:59 2021 +0700
Lucene.Net.Search.Join.ToParentBlockJoinCollector: Fixed nullable
conversion issue - null was converted to -1 in Java, so we must use -1 when the
item is not in the collection
---
src/Lucene.Net.Join/Support/ToParentBlockJoinCollector.cs | 3 ++-
src/Lucene.Net.Join/ToParentBlockJoinCollector.cs | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/src/Lucene.Net.Join/Support/ToParentBlockJoinCollector.cs
b/src/Lucene.Net.Join/Support/ToParentBlockJoinCollector.cs
index 648be74..bc872b0 100644
--- a/src/Lucene.Net.Join/Support/ToParentBlockJoinCollector.cs
+++ b/src/Lucene.Net.Join/Support/ToParentBlockJoinCollector.cs
@@ -405,6 +405,7 @@ namespace Lucene.Net.Join
{
return null;
}
+ slot = -1; // LUCENENET: In Java null is converted to -1 for
AccumulateGroups()
}
if (sortedGroups == null)
@@ -420,7 +421,7 @@ namespace Lucene.Net.Join
return null;
}
- return AccumulateGroups(slot == null ? -1 : slot, offset,
maxDocsPerGroup, withinGroupOffset, withinGroupSort, fillSortFields);
+ return AccumulateGroups(slot, offset, maxDocsPerGroup,
withinGroupOffset, withinGroupSort, fillSortFields);
}
/// <summary>
diff --git a/src/Lucene.Net.Join/ToParentBlockJoinCollector.cs
b/src/Lucene.Net.Join/ToParentBlockJoinCollector.cs
index df351b3..40dd034 100644
--- a/src/Lucene.Net.Join/ToParentBlockJoinCollector.cs
+++ b/src/Lucene.Net.Join/ToParentBlockJoinCollector.cs
@@ -403,6 +403,7 @@ namespace Lucene.Net.Search.Join
{
return null;
}
+ slot = -1; // LUCENENET: In Java null is converted to -1 for
AccumulateGroups()
}
if (sortedGroups == null)
@@ -418,7 +419,7 @@ namespace Lucene.Net.Search.Join
return null;
}
- return AccumulateGroups(slot == null ? -1 : slot, offset,
maxDocsPerGroup, withinGroupOffset, withinGroupSort, fillSortFields);
+ return AccumulateGroups(slot, offset, maxDocsPerGroup,
withinGroupOffset, withinGroupSort, fillSortFields);
}
/// <summary>