Revision 86f87418 transmissionHandler.c

View differences:

transmissionHandler.c
147 147
boolean recv_data_callback;
148 148

  
149 149
/*
150
 * helper function to get rid of a warning
151
 */
152
int min(int a, int b) {
153
	if (a > b) return b;
154
	return a;
155
}
156

  
157
/*
150 158
 * functions 
151 159
 */
152 160
/*
......
808 816
			if(set_Monitoring_header_pkt_cb != NULL) {
809 817
				iov[1].iov_len = (set_Monitoring_header_pkt_cb) (&(connectbuf[con_id]->external_socketID), msg_type);
810 818
			}
811
			pkt_len = fmin(connectbuf[con_id]->pmtusize - iov[2].iov_len - iov[1].iov_len - iov[0].iov_len, msg_len - offset) ;
819
			pkt_len = min(connectbuf[con_id]->pmtusize - iov[2].iov_len - iov[1].iov_len - iov[0].iov_len, msg_len - offset) ;
812 820

  
813 821
			iov[3].iov_len = pkt_len;
814 822
			iov[3].iov_base = msg + offset;

Also available in: Unified diff