Bugfix: Do not error on --release
mode
Check for "validation layers" should not panic in `--release` mode (which is enabled for debug mode).
This commit is contained in:
parent
6b3c83d913
commit
1def795b77
1 changed files with 1 additions and 3 deletions
|
@ -311,9 +311,7 @@ impl VulkanApp {
|
||||||
|
|
||||||
fn setup_debug_messenger(&mut self) -> Result<(), String> {
|
fn setup_debug_messenger(&mut self) -> Result<(), String> {
|
||||||
if !ENABLE_VALIDATION_LAYERS {
|
if !ENABLE_VALIDATION_LAYERS {
|
||||||
return Err(String::from(
|
return Ok(());
|
||||||
"Cannot setup debug messenger if validation layers is not enabled!",
|
|
||||||
));
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if self.vk_instance.is_null() {
|
if self.vk_instance.is_null() {
|
||||||
|
|
Loading…
Reference in a new issue