HylaFAX The world's
most advanced open source fax server
|
|
[
Date Prev][
Date Next][
Thread Prev][
Thread Next]
[
Date Index]
[
Thread Index]
Re: [hylafax-users] Multiple "MODEM No carrier"
Antonio,
Please try the attached patch. The problem was that conf.t1Timer is in
milliseconds and not seconds, and thus the timeout was 1000X too long.
Thanks,
Lee.
diff -Nru hylafax.orig/faxd/Class1.c++ hylafax/faxd/Class1.c++
--- hylafax.orig/faxd/Class1.c++ 2007-10-17 17:40:24.000000000 -0700
+++ hylafax/faxd/Class1.c++ 2007-10-18 11:40:35.461094816 -0700
@@ -1475,7 +1475,7 @@
* modem response at that point, anyway. So it is a good indicator for us.
* So we simply repeat AT+FRH=3 in that case.
*/
- } while (((u_int) Sys::now()-start < conf.t1Timer) && !gotframe && !wasTimeout() &&
+ } while (((u_int) Sys::now()-start < howmany(conf.t1Timer, 1000)) && !gotframe && !wasTimeout() &&
((conf.class1HasRHConnectBug && !frame.getLength() && lastResponse == AT_NOCARRIER && rhcnt++ < 30) ||
(docrp && crpcnt++ < 3 && switchingPause(emsg, 3) && transmitFrame(dir|FCF_CRP)))); /* triple switchingPause to avoid sending CRP during TCF */
return (gotframe);
diff -Nru hylafax.orig/faxd/Class1Recv.c++ hylafax/faxd/Class1Recv.c++
--- hylafax.orig/faxd/Class1Recv.c++ 2007-10-17 17:40:24.000000000 -0700
+++ hylafax/faxd/Class1Recv.c++ 2007-10-18 11:31:12.034748640 -0700
@@ -292,7 +292,7 @@
* time to make another attempt...
*/
if ((u_int) Sys::now()-start >= t1)
- break;
+ return (false);
if (frame.getFCF() != FCF_CRP) {
/*
* Historically we waited "Class1TrainingRecovery" (1500 ms)