X-Git-Url: http://git.marmaro.de/?a=blobdiff_plain;f=uip%2Fburst.c;h=fdc78f43ffa69ac629c11791ae51edfc0674a079;hb=f8960957ae53f962fe12e5a5eb4c01eb54cb4228;hp=725abec39bca86be769cdfa8d04236f1ad3fa220;hpb=9f9bfa91d88b3ca4cd9206c1f2b17c6d13ebcaba;p=mmh diff --git a/uip/burst.c b/uip/burst.c index 725abec..fdc78f4 100644 --- a/uip/burst.c +++ b/uip/burst.c @@ -216,11 +216,13 @@ find_delim(int msgnum, struct smsg *smsgs) for (c = 0; fgets(buffer, sizeof(buffer), in); c = buffer[0]) { if (strncmp(buffer, delim3, ld3) == 0 - && (msgp == 1 || c == '\n') - && ((cc = peekc(in)) == '\n' || - cc == EOF)) - break; - else + && (msgp == 1 || c == '\n')) { + cc = getc(in); + ungetc(cc, in); + if (cc == '\n' || cc == EOF) { + break; + } + } else pos += (long) strlen(buffer); }