$ uname -a
Linux 505cf5a8c892 5.15.133.1-microsoft-standard-WSL2 #1 SMP Thu Oct 5 21:02:42 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
$ ./ls_extended
ls_extended
It will be memory leak. sink is in src/vec.c:37.
The problem is when i go to if( flags & OPT_V )... else{}, the else is only return not free, so that memory leak.
Maybe the solution is add vec_destroy( & locs ); in main.c:54
thank you!
$ uname -a Linux 505cf5a8c892 5.15.133.1-microsoft-standard-WSL2 #1 SMP Thu Oct 5 21:02:42 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux $ ./ls_extended ls_extended
It will be memory leak. sink is in src/vec.c:37.
The problem is when i go to if( flags & OPT_V )... else{}, the else is only return not free, so that memory leak. Maybe the solution is add vec_destroy( & locs ); in main.c:54 thank you!