dlg99 commented on a change in pull request #12141:
URL: https://github.com/apache/pulsar/pull/12141#discussion_r714282575



##########
File path: 
managed-ledger/src/main/java/org/apache/bookkeeper/mledger/impl/ManagedLedgerImpl.java
##########
@@ -1602,7 +1605,7 @@ synchronized void createLedgerAfterClosed() {
     @Override
     public void rollCurrentLedgerIfFull() {
         log.info("[{}] Start checking if current ledger is full", name);
-        if (currentLedgerEntries > 0 && currentLedgerIsFull()) {
+        if (currentLedger != null && currentLedgerEntries > 0 && 
currentLedgerIsFull()) {

Review comment:
       essentially this is it. 




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to