fix minor shader related catches

this PR should fix a couple of minor GL & shader related bugs that I discovered when inspecting the gl3 render through openGL profiler.