make sure l is always initialized

I can't think of cases where we reach serialize_iri and path is NULL,
but let's keep the safe side and initialize l.  gcc 8 found this,
clang didn't.
This commit is contained in:
Omar Polo 2021-06-16 15:04:42 +00:00
parent 2d383cbd5f
commit 80fbf1e934
1 changed files with 1 additions and 1 deletions

2
iri.c
View File

@ -424,7 +424,7 @@ trim_req_iri(char *iri, const char **err)
int
serialize_iri(struct iri *i, char *buf, size_t len)
{
size_t l;
size_t l = 0;
/* in ex.c we receive empty "" strings as NULL */
if (i->schema == NULL || i->host == NULL) {