Errata

Async in C# 5.0

Errata for Async in C# 5.0

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 7
'Web Application Server Code' section

Regarding web server code, you don't mention servers in the Cloud.

Are there any other considerations when running in a cloud environment?

Pepe M  Jun 25, 2014 
Printed Page 10
3rd paragraph

The example source code does not seem to exist:

https://bitbucket.org/alexdavies74/faviconbrowser

Anonymous  Oct 03, 2020 
Printed Page 10
3rd paragraph

The example source code does not seem to exist:

https://bitbucket.org/alexdavies74/faviconbrowser

Tim Brandwood  Oct 03, 2020 
Printed Page 20
ist paragraph code snippet

2nd line of method's code block is:
byte[] bytes= await webclient.DownloadDataTaskAsync(....);

3rd paragraph defines the awaited WebClient method as:
Task<string> DownloadStringTaskAsync( string address);

Anonymous  May 27, 2015 
PDF Page 24
Async Methods Are Contagious example

hi
An async example in page 24 is not really asynchronous. GetPageSizeAsync() method runs in order for domains one after another and There isn't any Difference between the execution result of synchronous case and asynchronous have been written.

Mahdi Razavi  Jan 28, 2013 
Printed Page 44
Just before final para

This page has

IProgress<DownloadProgressChangedEventArgs>

whereas the next page has

Progress<Int>

Shouldn't the type parameters be the same?

Pepe M  Jun 24, 2014 
Printed Page 45
2nd paragraph

The sentence 'This is much the same...' is unclear for 2 reasons, I think:

1) The threading behaviour when continuing after an await has not been clearly discussed yet - I think that is the next chapter. I started wondering whether I had forgotten what I had read, because I would have remembered that!

2) "the fact that...could be called from any thread'...you are describing something as a 'fact' when actually, you are saying it doesn't happen.

Pepe M  Jun 17, 2014 
Printed Page 49
'await and SynchronizationContext' Section

The bullet point:

'The SynchronizationContext was one that doesn't actually switch threads'

The meaning of this is unclear.

Pepe M  Jun 24, 2014 
Printed Page 50
Whole Page

I think there should have been a normal listing in the book for the code in the diagram, in addition to the diagram.

Peter M  Jun 24, 2014 
Printed Page 50
Point 5

Typo: 'GetFaviconAsyncAsync' - 'Async' duplicated.

Pepe M  Jun 24, 2014 
Printed Page 50
#5

5. The UI thread leaves DownloadDataTaskAsync, and reaches the await in GetFaviconAsyncAsync.

It should be:

5. The UI thread leaves DownloadDataTaskAsync, and reaches the await in GetFaviconAsync.

Anonymous  Dec 13, 2018 
Printed Page 52
paragraph above the section "Interacting with Synchronous Code"

But if it’s an important thread of some kind, .NET will prefer to release it to do other things, and your method will resume on the thread pool
instead.

should be:

But if it’s an important thread of some kind, .NET will prefer to release it to do other things, and your method will resume on the thread instead.

Anonymous  Dec 13, 2018 
Printed Page 82
'Catching Exceptions' section

The exception caught is 'e':

catch (Exception e)

but when set is '<>t_ex' :

<>t__builder.SetException(<>t__ex)

Shouldn't they both have the same name?

Pepe M  Jun 23, 2014 
Printed Page 82
2nd Para - General Note

In the 'C' language, the 'case' parts of a switch have always been oridinary labels.

This is mentioned in 'The C Programming Language' by K&R, I think.

Also, see under 'Semantics' here:

http://en.wikipedia.org/wiki/Switch_statement

So 'goto case x' is really just a 'goto label', I think.

Pepe M  Jun 25, 2014