My latest changes.
Includes:
Increase powervu stream relay total combined audio and subtitle tracks to 16 (limit was 4 previously.)
Plus:
a few possible resource leak/memory leak fixes (thanks to tanaseiv)
some compiler warning fixes
Note - not updated on github yet. If no one reports problems I will create a pull request later.