Added API function iio_context_clone

This function can be used to duplicate one IIO context. It is useful in
multi-threaded software, so that each thread owns its own context.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Local backend: Added "clone" backend function

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Xml backend: Added "clone" backend function

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Network backend: Added "clone" backend function

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Network backend: Fix double free in OOM occasions

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
Added API function iio_create_default_context

This function will create a network context if the IIOD_REMOTE
environment variable is set to the hostname where the IIOD server
runs. If set to an empty string, the server will be discovered using
ZeroConf. If the environment variable is not set, a local context
will be created instead.

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>
ad9361-iiostream: Use iio_create_default_context

Signed-off-by: Paul Cercueil <paul.cercueil@analog.com>