avoid segfault on empty application name
avoid crash on sinks without names (loopbacks?)
fix another possible NULL strdup