Errata

Efficient Android Threading

Errata for Efficient Android Threading

Submit your own errata for this product.

The errata list is a list of errors and their corrections that were found after the product was released.

The following errata were submitted by our customers and have not yet been approved or disproved by the author or editor. They solely represent the opinion of the customer.

Color Key: Serious technical mistake Minor technical mistake Language or formatting error Typo Question Note Update

Version Location Description Submitted by Date submitted
Printed Page 43
onTextChanged(...) method

When writing to the "PipedWriter w" in line:

w.write(charSequence.subSequence(before, count).toString());

the wrong character is written if the user changes the place of the cursor.


Changing to:

w.write(charSequence.subSequence(before + start, count + start).toString());

fixes this issue.

Anonymous  Jul 09, 2015 
PDF Page 43
while(Thread.currentThread().isInterrupted()){

while(Thread.currentThread().isInterrupted()){
should be
while(!Thread.currentThread().isInterrupted()){

Anonymous  Mar 30, 2020 
PDF Page 49
Example code

Should mHandler be defined as a volatile field ? it is assigned in LooperThread and read in the Main thread.

Anonymous  Jan 13, 2019