[dahdi-commits] qwell: linux/trunk r5360 - /linux/trunk/drivers/dahdi/dahdi-base.c
SVN commits to the DAHDI project
dahdi-commits at lists.digium.com
Fri Nov 21 14:15:47 CST 2008
Author: qwell
Date: Fri Nov 21 14:15:47 2008
New Revision: 5360
URL: http://svn.digium.com/view/dahdi?view=rev&rev=5360
Log:
Fix a think-o in numeric comparison. Swap order to make it more clear.
(closes issue #13813)
Reported by: ys
Modified:
linux/trunk/drivers/dahdi/dahdi-base.c
Modified: linux/trunk/drivers/dahdi/dahdi-base.c
URL: http://svn.digium.com/view/dahdi/linux/trunk/drivers/dahdi/dahdi-base.c?view=diff&rev=5360&r1=5359&r2=5360
==============================================================================
--- linux/trunk/drivers/dahdi/dahdi-base.c (original)
+++ linux/trunk/drivers/dahdi/dahdi-base.c Fri Nov 21 14:15:47 2008
@@ -4045,13 +4045,13 @@
if (copy_from_user(&tdp, (struct dahdi_dialparams *) data, sizeof(tdp)))
return -EFAULT;
- if ((tdp.dtmf_tonelen <= 4000) || (tdp.dtmf_tonelen >= 10)) {
+ if ((tdp.dtmf_tonelen >= 10) && (tdp.dtmf_tonelen <= 4000)) {
global_dialparams.dtmf_tonelen = tdp.dtmf_tonelen;
}
- if ((tdp.mfv1_tonelen <= 4000) || (tdp.mfv1_tonelen >= 10)) {
+ if ((tdp.mfv1_tonelen >= 10) && (tdp.mfv1_tonelen <= 4000)) {
global_dialparams.mfv1_tonelen = tdp.mfv1_tonelen;
}
- if ((tdp.mfr2_tonelen <= 4000) || (tdp.mfr2_tonelen >= 10)) {
+ if ((tdp.mfr2_tonelen >= 10) && (tdp.mfr2_tonelen <= 4000)) {
global_dialparams.mfr2_tonelen = tdp.mfr2_tonelen;
}
More information about the dahdi-commits
mailing list