assemble_kiss(buf, l)
void assemble_kiss(buf, l)
assemble_kiss(buf, l)unsigned char *buf;int l;{	int i;	unsigned char c;	for(i=0;i<l;i++,buf++){		c = *buf;		if(c==FEND){			if(ifcount>0){				/* Make sure that the control byte is zero */				if(*iframe=='\0' || *iframe==0x10) {					/* Room for CRC in buffer? */					if(ifcount < (MAX_FRAME - 2)) {						stats.kiss_in++;						from_kiss(iframe+1,ifcount-1);					} else {						stats.kiss_toobig++;						LOGL2("assemble_kiss: dumped - frame too large\n");					}				} else {					stats.kiss_badtype++;					LOGL2("assemble_kiss: dumped - control byte non-zero\n");				}			}			ifcount = 0;			iescaped = 0;			ifptr = iframe;			continue;		}		if(c==FESC){			iescaped=1;			continue;		}		if(iescaped){			if(c==TFEND)c = FEND;			if(c==TFESC)c = FESC;			iescaped = 0;		}		if(ifcount < MAX_FRAME){			*ifptr = c;			ifptr++;			ifcount++;		}	} /* for every character in the buffer */}