 <p>Just a quick hunch: </p> <p>Have you tried calling glShaderSource with NULL as length parameter? In that case OpenGL will assume your code to be null-terminated.</p> <p>(Edited because of stupidity)</p>