[comp.windows.x] Bug in server/ddx/mi/mispritest.h

law@super.super.org (Jeffrey A Law) (05/25/91)

The definition of LINE_SORT contains the argument "y2" twice.  I believe
the first one should have been "y1".  Here is a patch:

*** mispritest.h.orig   Fri May 24 14:26:16 1991
--- mispritest.h        Fri May 24 14:26:37 1991
***************
*** 92,98 ****
   */
  #define SPN_OVERLAP(pCbox,y,x,w) BOX_OVERLAP((pCbox),(x),(y),(x)+(w),(y))

! #define LINE_SORT(x1,y2,x2,y2) \
  { int _t; \
    if (x1 > x2) { _t = x1; x1 = x2; x2 = _t; } \
    if (y1 > y2) { _t = y1; y1 = y2; y2 = _t; } }
--- 92,98 ----
   */
  #define SPN_OVERLAP(pCbox,y,x,w) BOX_OVERLAP((pCbox),(x),(y),(x)+(w),(y))

! #define LINE_SORT(x1,y1,x2,y2) \
  { int _t; \
    if (x1 > x2) { _t = x1; x1 = x2; x2 = _t; } \
    if (y1 > y2) { _t = y1; y1 = y2; y2 = _t; } }