Skip to content

Commit c99a026

Browse files
devnexencmb69
authored andcommitted
Fix memory leak on invalid port
Closes GH-7911.
1 parent 9781085 commit c99a026

File tree

2 files changed

+4
-0
lines changed

2 files changed

+4
-0
lines changed

NEWS

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,9 @@ PHP NEWS
22
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
33
?? ??? 2022, PHP 8.0.16
44

5+
- FPM:
6+
. Fixed memory leak on invalid port. (David Carlier)
7+
58
- Sockets:
69
. Fixed ext/sockets build on Haiku. (David Carlier)
710

sapi/fpm/fpm/fpm_sockets.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -336,6 +336,7 @@ static int fpm_socket_af_inet_listening_socket(struct fpm_worker_pool_s *wp) /*
336336

337337
if (port == 0) {
338338
zlog(ZLOG_ERROR, "invalid port value '%s'", port_str);
339+
free(dup_address);
339340
return -1;
340341
}
341342

0 commit comments

Comments
 (0)