X-Git-Url: https://git.nihav.org/?a=blobdiff_plain;f=nihav-vivo%2Fsrc%2Fdemuxers%2Fmod.rs;h=145dafc277893e9585a82fa122485f78f885f956;hb=34219db3e2b43a690418e3d157b59a9f052ad343;hp=2f4a94ddd6bbe6a7fbf0ea3bd3925e0798bfca76;hpb=ac818eac7671fa8ddfea5aa4fb86fc0b5ab82d2e;p=nihav.git diff --git a/nihav-vivo/src/demuxers/mod.rs b/nihav-vivo/src/demuxers/mod.rs index 2f4a94d..145dafc 100644 --- a/nihav-vivo/src/demuxers/mod.rs +++ b/nihav-vivo/src/demuxers/mod.rs @@ -2,9 +2,14 @@ use nihav_core::demuxers::*; #[allow(unused_macros)] +#[cfg(debug_assertions)] macro_rules! validate { ($a:expr) => { if !$a { println!("check failed at {}:{}", file!(), line!()); return Err(DemuxerError::InvalidData); } }; } +#[cfg(not(debug_assertions))] +macro_rules! validate { + ($a:expr) => { if !$a { return Err(DemuxerError::InvalidData); } }; +} #[cfg(feature="demuxer_vivo")] mod vivo;