[CLEANUP] stream_interface: use inline functions to manipulate targets

The connection target involves a type and a union of pointers, let's
make the code cleaner using simple wrappers.
8 files changed