rem: n = read(fd, buf, sizeof(buf)-1); if (n > 0) { rwrite(FERROR, buf, n);
add: read_loop(fd, buf, 4); tag = IVAL(buf, 0);  len = tag & 0xFFFFFF; tag = tag >> 24; tag -= MPLEX_BASE;  while (len) { n = len; if (n > (sizeof(buf)-1)) n = sizeof(buf)-1; read_loop(fd, buf, n); rwrite((enum logcode)tag, buf, n); len -= n;
context: static void read_error_fd(void){	char buf[200];	int n;	int fd = io_error_fd;	io_error_fd = -1;	n = read(fd, buf, sizeof(buf)-1);	if (n > 0) {		rwrite(FERROR, buf, n);	}	io_error_fd = fd;}