When g_option_context_parse fails, context and error variables are not getting free'd
which results in memory leaks. Free'ing the same.
And replacing g_error_free with g_clear_error, which checks if the error being passed
is not NULL and sets the variable to NULL on free'ing.
https://bugzilla.gnome.org/show_bug.cgi?id=753863
This allows users to run multiple servers on different ports for testing.
Only done for examples that actually take arguments and hence are capable of
outputting different streams for each instance on each port.
https://bugzilla.gnome.org/show_bug.cgi?id=742115