Hi,
> You missed call to free(globdir); at end.
the buffer pointed to be globdir is supposed to stay, to be reused by
later invocations of foreachdir(). It's kind of a lazily initialized
global scratch buffer to construct intermediate path strings.
Good catch on the globfree() though, the way it
Rafa?? Mi??ecki wrote:
> From: Rafa?? Mi??ecki
> Alloc globdir buffer dynamically and simply use realloc when needed.
> This fixes e.g. segmentation fault in jffs2reset due to an infinite
> recurrency when dealing with longs paths.
> Signed-off-by: Rafa?? Mi??ecki
> ---
> libfstools/overlay.c
From: Rafał Miłecki
Alloc globdir buffer dynamically and simply use realloc when needed.
This fixes e.g. segmentation fault in jffs2reset due to an infinite
recurrency when dealing with longs paths.
Signed-off-by: Rafał Miłecki
---
libfstools/overlay.c | 21 +
1 file change