nRF Connect SDK API 0.1.0
Loading...
Searching...
No Matches

◆ get_line_len()

int get_line_len ( const char *  buf,
size_t  buf_len 
)

Get length of a string (or a line). String shall be '\0' terminated. Newline characters are not included in the count. Example: "+CEREG: 1" -> 9 "+CEREG: 1\\r\\n" -> 9.

Parameters
[in]bufString buffer
[in]buf_lenInput buffer length
Returns
length of the string -1 if the string is not '\0' terminated