concat_path(): Add missing free() calls
This commit is contained in:
부모
b5f83499f3
커밋
40d23af355
2
exile.c
2
exile.c
@ -816,11 +816,13 @@ char *concat_path(const char *first, const char *second)
|
|||||||
if(written < 0)
|
if(written < 0)
|
||||||
{
|
{
|
||||||
EXILE_LOG_ERROR("Error during path concatination\n");
|
EXILE_LOG_ERROR("Error during path concatination\n");
|
||||||
|
free(result);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
if(written >= PATH_MAX)
|
if(written >= PATH_MAX)
|
||||||
{
|
{
|
||||||
EXILE_LOG_ERROR("path concatination truncated\n");
|
EXILE_LOG_ERROR("path concatination truncated\n");
|
||||||
|
free(result);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
return result;
|
return result;
|
||||||
|
불러오는 중...
Reference in New Issue
Block a user