mirror of
https://github.com/obgm/libcoap.git
synced 2026-12-03 03:01:05 +03:00
uri.[hc]: improved support for 'coaps' URI scheme
This commit is contained in:
1 parent
5180ae3753
commit
3a127a3816
2 files changed
+24
No files matched your search
@@ -74,6 +74,10 @@ coap_split_uri(unsigned char *str_var, size_t len, coap_uri_t *uri) {
|
||||
/* There might be an additional 's', indicating the secure version: */
|
||||
if (len && (secure = tolower(*p) == 's')) {
|
||||
++p; --len;
|
||||
uri->scheme = COAP_URI_SCHEME_COAPS;
|
||||
uri->port = COAPS_DEFAULT_PORT;
|
||||
} else {
|
||||
uri->scheme = COAP_URI_SCHEME_COAP;
|
||||
}
|
||||
|
||||
q = (unsigned char *)"://";
|
||||
|
||||
Reference in new issue
Block a user