Re: Dillo and Irix

eocene <[email protected]>
Newsgroups gmane.comp.web.dillo.devel
Message-ID <[email protected]>
Having thought about it probably too much over the past however many days,
I haven't thought of a good reason not to stick it all in an ifdef like

#if defined(__sgi)
         /* IRIX does not conform to C99; if the entire argument did not fit
          * into the buffer, n = buffer space used (minus 1 for terminator)
          */
         if (n > -1 && n + 1 < ds->sz - ds->len) {
            ds->len += n;      /* Success! */
            break;
         } else {
            n_sz = ds->sz * 2;
         }
#else
         if (n > -1 && n < ds->sz - ds->len) {
            ds->len += n;      /* Success! */
            break;
         } else if (n > -1) {  /* glibc >= 2.1 */
            n_sz = ds->len + n + 1;
         } else {              /* old glibc */
            n_sz = ds->sz * 2;
         }
#endif

and be done with it.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.