htsp: fix NULL ptr username, do it properly this time!

This commit is contained in:
Adam Sutton 2014-03-14 20:23:40 +00:00
parent 9398e6dac3
commit 3f3fdc8af1

View file

@ -432,7 +432,7 @@ htsp_generate_challenge(htsp_connection_t *htsp)
*/
static int
htsp_user_access_channel(htsp_connection_t *htsp, channel_t *ch) {
if (!access_tag_only(htsp->htsp_username))
if (!access_tag_only(htsp->htsp_username ?: ""))
return 1;
else {
if (!ch) return 0;