FS-6956 modify commit 16365501 to use one single line which is only tolerable way to have bracket-less if stmts.

This commit is contained in:
Anthony Minessale 2014-11-03 14:03:04 -06:00
parent 5dee5ce1d5
commit b5d8fa9f46
1 changed files with 1 additions and 3 deletions

View File

@ -129,9 +129,7 @@ SWITCH_DECLARE(switch_stun_packet_t *) switch_stun_packet_parse(uint8_t *buf, ui
packet = (switch_stun_packet_t *) buf;
packet->header.type = ntohs(packet->header.type);
packet->header.length = ntohs(packet->header.length);
if (packet->header.length > (bytes_left -= 20))
return NULL;
if (packet->header.length > (bytes_left -= 20)) return NULL;
/*
* Check packet type (RFC3489(bis?) values)