Fix EUA order for case where "stop address" is equal to current
authorGregory Minshall <minshall@ucbvax.Berkeley.EDU>
Mon, 14 Mar 1988 14:24:46 +0000 (06:24 -0800)
committerGregory Minshall <minshall@ucbvax.Berkeley.EDU>
Mon, 14 Mar 1988 14:24:46 +0000 (06:24 -0800)
buffer address.

SCCS-vsn: usr.bin/tn3270/ctlr/outbound.c 3.2

usr/src/usr.bin/tn3270/ctlr/outbound.c

index 05efe33..1d3cec9 100644 (file)
@@ -20,7 +20,7 @@
  */
 
 #ifndef lint
  */
 
 #ifndef lint
-static char sccsid[] = "@(#)outbound.c 3.1 (Berkeley) %G%";
+static char sccsid[] = "@(#)outbound.c 3.2 (Berkeley) %G%";
 #endif /* lint */
 
 
 #endif /* lint */
 
 
@@ -422,14 +422,15 @@ int       control;                                /* this buffer ended block? */
                 */
                i = WhereAttrByte(BufferAddress);
                c = FieldAttributes(i);
                 */
                i = WhereAttrByte(BufferAddress);
                c = FieldAttributes(i);
-               for (i = Addr3270(buffer[0], buffer[1]); i != BufferAddress;
-                               BufferAddress = ScreenInc(BufferAddress)) {
+               i = Addr3270(buffer[0], buffer[1]);
+               do {
                    if (IsStartField(BufferAddress)) {
                        c = FieldAttributes(BufferAddress);
                    } else if (!IsProtectedAttr(BufferAddress, c)) {
                        AddHost(BufferAddress, 0);
                    }
                    if (IsStartField(BufferAddress)) {
                        c = FieldAttributes(BufferAddress);
                    } else if (!IsProtectedAttr(BufferAddress, c)) {
                        AddHost(BufferAddress, 0);
                    }
-               }
+                   BufferAddress = ScreenInc(BufferAddress);
+               } while (i != BufferAddress);
                buffer += 2;
                count -= 2;
                break;
                buffer += 2;
                count -= 2;
                break;