HLS M3U8 manifest handling in C