patch-pipe_c 532 B

123456789101112131415161718192021
  1. $OpenBSD: patch-pipe_c,v 1.3 2017/05/12 20:27:25 naddy Exp $
  2. Index: pipe.c
  3. --- pipe.c.orig
  4. +++ pipe.c
  5. @@ -36,12 +36,13 @@ getnum(int r0, int c0, int rn, int cn, int fd)
  6. for (c = c0, pp = ATBL(tbl, r, c); c <= cn; pp++, c++) {
  7. *line = '\0';
  8. p = *pp;
  9. - if (p)
  10. + if (p) {
  11. if (p->cellerror)
  12. sprintf(line, "%s", (*pp)->cellerror == CELLERROR ?
  13. "ERROR" : "INVALID");
  14. else if (p->flags & is_valid)
  15. sprintf(line, "%.15g", p->v);
  16. + }
  17. if (c < cn)
  18. strcat(line, "\t");
  19. else