r300g: fix possible crash when shader compilation fails
This hopefully fixes the crash in the FDO bug #27634, not the bug itself.
This commit is contained in:
@@ -278,7 +278,10 @@ static void r300_translate_fragment_shader(
|
||||
"Giving up...\n");
|
||||
abort();
|
||||
}
|
||||
|
||||
rc_destroy(&compiler.Base);
|
||||
r300_dummy_fragment_shader(r300, shader);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Initialize numbers of constants for each type. */
|
||||
|
||||
@@ -330,7 +330,10 @@ void r300_translate_vertex_shader(struct r300_context* r300,
|
||||
"Giving up...\n");
|
||||
abort();
|
||||
}
|
||||
|
||||
rc_destroy(&compiler.Base);
|
||||
r300_dummy_vertex_shader(r300, vs);
|
||||
return;
|
||||
}
|
||||
|
||||
/* Initialize numbers of constants for each type. */
|
||||
|
||||
Reference in New Issue
Block a user