Merge pull request #881 from timgates42/bugfix_typo_terminated

docs: Fix simple typo, termined -> terminated
This commit is contained in:
Michael Grunder 2020-09-27 21:04:58 -07:00 committed by GitHub
commit b47fae4e70
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

4
sds.c
View File

@ -72,7 +72,7 @@ static inline char sdsReqType(size_t string_size) {
* and 'initlen'. * and 'initlen'.
* If NULL is used for 'init' the string is initialized with zero bytes. * If NULL is used for 'init' the string is initialized with zero bytes.
* *
* The string is always null-termined (all the sds strings are, always) so * The string is always null-terminated (all the sds strings are, always) so
* even if you create an sds string with: * even if you create an sds string with:
* *
* mystring = sdsnewlen("abc",3); * mystring = sdsnewlen("abc",3);
@ -415,7 +415,7 @@ sds sdscpylen(sds s, const char *t, size_t len) {
return s; return s;
} }
/* Like sdscpylen() but 't' must be a null-termined string so that the length /* Like sdscpylen() but 't' must be a null-terminated string so that the length
* of the string is obtained with strlen(). */ * of the string is obtained with strlen(). */
sds sdscpy(sds s, const char *t) { sds sdscpy(sds s, const char *t) {
return sdscpylen(s, t, strlen(t)); return sdscpylen(s, t, strlen(t));