Clear errno if no path

Signed-off-by: Adrien Gallouët <adrien@gallouet.fr>
This commit is contained in:
Adrien Gallouët
2018-03-12 14:59:59 +00:00
parent ae3f4ed9ac
commit 87d9806a88

4
mud.c
View File

@@ -451,8 +451,10 @@ mud_get_path(struct mud *mud, struct sockaddr_storage *local_addr,
return path;
}
if (!create)
if (!create) {
errno = 0;
return NULL;
}
struct mud_path *path = NULL;