fixed flags max_list bug for ds_select_*
fixed flags max_list bug for ds_select_*
Changes to stop keepalives on unregisters

Observed cases where keepalives from `nat_traversal` continued after unregister were traced back to a few lines of code which prevented stopping keepalives on unregister events.
core: introducing OpenSIPS contexts

A context is simply a data buffer. It can also be seen as a key-value
database, where different pieces of code register certain keys, in order
to maintain their values within each newly created context.

Contexts may be attached to any structure. The primitives defined in
"context.h" represent a generic way of registering/storing/fetching
data.
core: export sip_msg context operations

All sip_msg structures may now hold additional data within a context.
tm: export transaction context operations

All transactions may now hold additional context-specific data.
Data can be stored/fetched using the newly added functions in tm_binds.
Disable MI commands when presence is in lib mode.

Reported by Carlos Oliva @telematico, closing #382

(cherry picked from commit 7058396dfff62769a58103517ae42bf57078b8bd)
Add end_sub_on_timeout module parameter.

If a presence subscription should be automatically terminated (destroyed) when receiving a SIP timeout (408) for a sent NOTIFY requests.
Closes feature request #380.
Filename in script actions must be non-null.
Only update the dialog timeout in case we are in established state - otherwise it might lead to multiple unrefs related to multiple removal from timer list
(cherry picked from commit e515134cc1cd7fceafad60a620f5e77331de682e)
Since the dialog timeout is not done under dialog lock, we might have cases where the state is checked and is established, but until we get to update the timer, the dialog transitions to terminated & removes it from the timer.
Use marker that's set under d_timer lock in order to avoid this
fix_nated_sdp: oldmediaip replaced with oldcip(c=) and oldoip(o=)
Merge branch 'master' of https://github.com/OpenSIPS/opensips
More fixing on mk_action usage (function name was added).
Merge remote-tracking branch 'upstream/master'