]> git.ipfire.org Git - thirdparty/HylaFAX.git/commitdiff
Fix a bit of flow logic in recvPage
authorAidan Van Dyk <aidan@ifax.com>
Wed, 14 Mar 2007 18:31:02 +0000 (18:31 +0000)
committerAidan Van Dyk <aidan@ifax.com>
Wed, 14 Mar 2007 18:31:02 +0000 (18:31 +0000)
From Lee:
|commit d609116f05c61d1aaffdb5a306ed611d40301524
|Author: Lee Howard <faxguy@howardsilvan.com>
|Date:   Mon Jul 17 18:17:40 2006 +0000
|
|    It's a very rare circumstance, apparently, but this fixes just a bit of
|        flow logic.

faxd/Class1Recv.c++

index 3388a5b389a08638e85b43ebe2007a051c3d00d9..ea8fe5cbde21cc9692df7bf900964bc022dc6f24 100644 (file)
@@ -717,7 +717,7 @@ Class1Modem::recvPage(TIFF* tif, u_int& ppm, fxStr& emsg, const fxStr& id)
                            trainok = recvTraining();
                            messageReceived = (!trainok && lastResponse == AT_FRH3);
                        }
-                   } while (!trainok && traincount++ < 3 && recvFrame(frame, FCF_RCVR, timer));
+                   } while (!trainok && traincount++ < 3 && lastResponse != AT_FRH3 && recvFrame(frame, FCF_RCVR, timer));
                    if (messageReceived && lastResponse == AT_FRH3 && waitFor(AT_CONNECT,0)) {
                        messageReceived = false;
                        if (recvFrame(frame, FCF_RCVR, conf.t2Timer, true)) {