--- old/src/java.desktop/share/classes/javax/swing/DefaultListSelectionModel.java	2018-02-15 18:33:18.179802332 +0530
+++ new/src/java.desktop/share/classes/javax/swing/DefaultListSelectionModel.java	2018-02-15 18:33:17.943684332 +0530
@@ -455,6 +455,7 @@
 
     /** {@inheritDoc} */
     public void clearSelection() {
+        updateLeadAnchorIndices(-1, -1);
         removeSelectionIntervalImpl(minIndex, maxIndex, false);
     }
 
@@ -691,18 +692,14 @@
         }
 
         int leadIndex = this.leadIndex;
-        if (leadIndex == 0 && rmMinIndex == 0) {
-            // do nothing
-        } else if (leadIndex > rmMaxIndex) {
+        if (leadIndex > rmMaxIndex) {
             leadIndex = this.leadIndex - gapLength;
         } else if (leadIndex >= rmMinIndex) {
             leadIndex = rmMinIndex - 1;
         }
 
         int anchorIndex = this.anchorIndex;
-        if (anchorIndex == 0 && rmMinIndex == 0) {
-            // do nothing
-        } else if (anchorIndex > rmMaxIndex) {
+        if (anchorIndex > rmMaxIndex) {
             anchorIndex = this.anchorIndex - gapLength;
         } else if (anchorIndex >= rmMinIndex) {
             anchorIndex = rmMinIndex - 1;
