PetitParser has a PPContext in newer versions but the GST code
is older and doesn't have it. Provide an alternative impl.
Provide >>#do: for the SIPVia for Pharo to print the data
Avoid importing MIMERWStream as it is dead in Pharo
On the sysmoBTS (ARM7TDMI) the parsing of a simple response
with quoted string takes up to 200ms. Parsing the single
digest line takes 40ms itself. Create a custom parser to
speed things up to avoid the backtracking between three
optional parsers that are combined in a choice.
* Do not use >>#instVarNamed:put: but add selectors
* Pre-allocate some arrays with a default string to avoid
re-allocations at the start
* Share same parser trees to avoid construction costs
* Remove some lazy allocation and always allocate it
So this code acks the 401 Unauthorized message. It is possible
that this message is lost on the way we will not be able to
respond to the 401 again. The right thing would be to "fork" off
the transaction to deal with re-transmissions.
In case the remote will do a re-invite to verify that we are
still aware of the call we need to handle >>#sessionAcked:dialog:
This probably got introduced when I introduced the incoming
call support that will send a 200 and receive the ACK.
The incoming call will print a warning that session->session is
not a valid state transition but nothing bad will happen.