mirror of
https://github.com/rkd77/elinks.git
synced 2025-02-02 15:09:23 -05:00
set_dom_string(): take length as size_t; -1 means use strlen() to get size
This commit is contained in:
parent
27116d6385
commit
5ff0849eb3
@ -10,10 +10,10 @@ struct dom_string {
|
||||
{ (strlength) == -1 ? sizeof(strvalue) - 1 : (strlength), (strvalue) }
|
||||
|
||||
static inline void
|
||||
set_dom_string(struct dom_string *string, unsigned char *value, uint16_t length)
|
||||
set_dom_string(struct dom_string *string, unsigned char *value, size_t length)
|
||||
{
|
||||
string->string = value;
|
||||
string->length = length;
|
||||
string->length = length == -1 ? strlen(value) : length;
|
||||
}
|
||||
|
||||
static inline int
|
||||
|
Loading…
x
Reference in New Issue
Block a user