Merge "RemotePrintDocument might get destroyed in constructor" into nyc-dev am: c37a323
am: 2ff245e
* commit '2ff245e3ec47148a88c869a25f1ee118ab2cd83f':
RemotePrintDocument might get destroyed in constructor
Change-Id: I7f75a23dc9ca3a1750252ef5a5a6ff8c64ca25ea
This commit is contained in:
@@ -178,6 +178,8 @@ public final class RemotePrintDocument {
|
||||
}
|
||||
if (mState == STATE_FAILED) {
|
||||
Log.w(LOG_TAG, "Failed before start.");
|
||||
} else if (mState == STATE_DESTROYED) {
|
||||
Log.w(LOG_TAG, "Destroyed before start.");
|
||||
} else {
|
||||
if (mState != STATE_INITIAL) {
|
||||
throw new IllegalStateException("Cannot start in state:" + stateToString(mState));
|
||||
@@ -267,7 +269,7 @@ public final class RemotePrintDocument {
|
||||
}
|
||||
if (mState != STATE_STARTED && mState != STATE_UPDATED
|
||||
&& mState != STATE_FAILED && mState != STATE_CANCELING
|
||||
&& mState != STATE_CANCELED) {
|
||||
&& mState != STATE_CANCELED && mState != STATE_DESTROYED) {
|
||||
throw new IllegalStateException("Cannot finish in state:"
|
||||
+ stateToString(mState));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user