mirror of
https://repo.or.cz/socat.git
synced 2025-07-14 07:23:23 +00:00
Fixed possible crash or fail of option ip-add-membership with two parameters
This commit is contained in:
parent
bcca5a3b9a
commit
920ed1f0a3
7 changed files with 30 additions and 4 deletions
|
@ -48,7 +48,8 @@ int xio_chdir(
|
|||
free(tmp_dir);
|
||||
return -1;
|
||||
}
|
||||
*orig_dir = Realloc(*orig_dir, strlen(*orig_dir)+1);
|
||||
/*0 *orig_dir = Realloc(*orig_dir, strlen(*orig_dir)+1); */
|
||||
*orig_dir = Realloc3(*orig_dir, strlen(*orig_dir)+1, PATH_MAX);
|
||||
|
||||
if (Chdir(tmp_dir) < 0) {
|
||||
Error2("chdir(\"%s\"): %s", tmp_dir, strerror(errno));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue