mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-12-22 10:30:13 +00:00
code style
This commit is contained in:
parent
19e08de0e2
commit
47df9c4e6e
@ -350,7 +350,7 @@ parse_url(const char *url, char *host, uint16_t *portptr, char *path)
|
||||
}
|
||||
|
||||
/* check if host is null terminated */
|
||||
if (!memchr(host, 0, MAX_HOSTLEN)) {
|
||||
if(!memchr(host, 0, MAX_HOSTLEN)) {
|
||||
return 0;
|
||||
}
|
||||
|
||||
@ -419,11 +419,11 @@ event(struct tcp_socket *tcps, void *ptr,
|
||||
tcp_socket_send_str(tcps, "Host: ");
|
||||
/* If we have IPv6 host, add the '[' and the ']' characters
|
||||
to the host. As in rfc2732. */
|
||||
if (memchr(host, ':', MAX_HOSTLEN)) {
|
||||
if(memchr(host, ':', MAX_HOSTLEN)) {
|
||||
tcp_socket_send_str(tcps, "[");
|
||||
}
|
||||
tcp_socket_send_str(tcps, host);
|
||||
if (memchr(host, ':', MAX_HOSTLEN)) {
|
||||
if(memchr(host, ':', MAX_HOSTLEN)) {
|
||||
tcp_socket_send_str(tcps, "]");
|
||||
}
|
||||
tcp_socket_send_str(tcps, "\r\n");
|
||||
|
Loading…
Reference in New Issue
Block a user