r300g: only check for an empty shader if there are no compile errors