Name
cyg_mdns_strlen_uncompressed — Length of uncompressed encoded string
Synopsis
#include <mdns.h>
cyg_uint16 cyg_mdns_strlen_uncompressed(const cyg_uint8 *us);
Description
This function is used to calculate the length of an uncompressed,
encoded string terminated by a zero-length (NUL)
field.
![]() | Note |
|---|---|
This function is not available if the system is not configured
with |
static const cyg_uint8 encoded_string[] = {
0x08,'t','e','s','t','n','a','m','e',
0x05,'_','h','t','t','p',
0x00
};
…
cyg_uint16 elen = cyg_mdns_strlen_uncompressed(encoded_string);
// elen == ((1 + 8) + (1 + 5) + 1) == 16Return value
The number of bytes occupied by the encoded string.
| 2025-10-02 | eCosPro Non-Commercial Public License |


![[Note]](pix/note.png)

