Print this page
5083 avoid undefined order of operations in assignments

*** 35,46 **** * University Acknowledgment- Portions of this document are derived from * software developed by the University of California, Berkeley, and its * contributors. */ - #pragma ident "%Z%%M% %I% %E% SMI" - #include "tdef.h" #include "tw.h" #include "ext.h" #include <ctype.h> --- 35,44 ----
*** 269,279 **** int base, wid; tchar i; int delim, emsz, k; int savhp, savapts, savapts1, savfont, savfont1, savpts, savpts1; ! base = numtab[ST].val = numtab[ST].val = wid = numtab[CT].val = 0; if (ismot(i = getch())) return (0); delim = cbits(i); savhp = numtab[HP].val; numtab[HP].val = 0; --- 267,277 ---- int base, wid; tchar i; int delim, emsz, k; int savhp, savapts, savapts1, savfont, savfont1, savpts, savpts1; ! base = numtab[ST].val = wid = numtab[CT].val = 0; if (ismot(i = getch())) return (0); delim = cbits(i); savhp = numtab[HP].val; numtab[HP].val = 0;