1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 03:40:34 +02:00

Changes from arch/CVS synchronization

This commit is contained in:
Ludovic Courtès 2007-09-02 10:55:58 +00:00
parent d7c0c26d88
commit 1ac5fb45bc
4 changed files with 17 additions and 3 deletions

View file

@ -1,3 +1,7 @@
2007-09-02 Ludovic Courtès <ludo@gnu.org>
* NEWS: Mention memory leak fix in `make-socket-address'.
2007-09-01 Ludovic Courtès <ludo@gnu.org> 2007-09-01 Ludovic Courtès <ludo@gnu.org>
* NEWS: Mention duplicate binding warnings to stderr. * NEWS: Mention duplicate binding warnings to stderr.

1
NEWS
View file

@ -43,6 +43,7 @@ Changes in 1.8.3 (since 1.8.2)
** Expressions like "(set! 'x #t)" no longer yield a crash ** Expressions like "(set! 'x #t)" no longer yield a crash
** Warnings about duplicate bindings now go to stderr ** Warnings about duplicate bindings now go to stderr
** A memory leak in `make-socket-address' was fixed
** Build problems on Solaris fixed ** Build problems on Solaris fixed
* Implementation improvements * Implementation improvements

View file

@ -1,3 +1,8 @@
2007-09-02 Ludovic Courtès <ludo@gnu.org>
* socket.c (scm_make_socket_address): Free C_ADDRESS after use.
This fixes a memory leak.
2007-08-26 Han-Wen Nienhuys <hanwen@lilypond.org> 2007-08-26 Han-Wen Nienhuys <hanwen@lilypond.org>
* fports.c gc-card.c gc.c gc.h ioext.c ports.c ports.h weaks.h * fports.c gc-card.c gc.c gc.h ioext.c ports.c ports.h weaks.h

View file

@ -1262,15 +1262,19 @@ SCM_DEFINE (scm_make_socket_address, "make-socket-address", 2, 0, 1,
"@code{connect} for details).") "@code{connect} for details).")
#define FUNC_NAME s_scm_make_socket_address #define FUNC_NAME s_scm_make_socket_address
{ {
SCM result = SCM_BOOL_F;
struct sockaddr *c_address; struct sockaddr *c_address;
size_t c_address_size; size_t c_address_size;
c_address = scm_c_make_socket_address (family, address, args, c_address = scm_c_make_socket_address (family, address, args,
&c_address_size); &c_address_size);
if (!c_address) if (c_address != NULL)
return SCM_BOOL_F; {
result = scm_from_sockaddr (c_address, c_address_size);
free (c_address);
}
return (scm_from_sockaddr (c_address, c_address_size)); return result;
} }
#undef FUNC_NAME #undef FUNC_NAME