Enlightenment CVS committal Author : mej Project : eterm Module : libast
Dir : eterm/libast/src Modified Files: socket.c url.c Log Message: Thu Feb 5 16:31:43 2004 Michael Jennings (mej) Plugged a few leaks and cleaned up one uninitialized parameter problem. =================================================================== RCS file: /cvsroot/enlightenment/eterm/libast/src/socket.c,v retrieving revision 1.18 retrieving revision 1.19 diff -u -3 -r1.18 -r1.19 --- socket.c 4 Feb 2004 17:51:26 -0000 1.18 +++ socket.c 5 Feb 2004 21:29:38 -0000 1.19 @@ -21,7 +21,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -static const char cvs_ident[] = "$Id: socket.c,v 1.18 2004/02/04 17:51:26 mej Exp $"; +static const char cvs_ident[] = "$Id: socket.c,v 1.19 2004/02/05 21:29:38 mej Exp $"; #ifdef HAVE_CONFIG_H # include <config.h> @@ -426,6 +426,7 @@ ASSERT_RVAL(!SPIF_SOCKET_ISNULL(self), SPIF_NULL_TYPE(socket)); addr = SPIF_ALLOC(sockaddr); + len = SPIF_SIZEOF_TYPE(sockaddr); do { newfd = accept(self->fd, addr, &len); } while ((newfd < 0) && ((errno == EAGAIN) || (errno == EWOULDBLOCK))); @@ -444,6 +445,7 @@ } else if (SPIF_SOCKET_FLAGS_IS_SET(self, SPIF_SOCKET_FLAGS_FAMILY_UNIX)) { tmp->remote_url = spif_url_new_from_unixaddr(SPIF_CAST(unixsockaddr) addr); } + SPIF_DEALLOC(addr); if (SPIF_SOCKET_FLAGS_IS_SET(self, SPIF_SOCKET_FLAGS_NBIO)) { spif_socket_set_nbio(tmp); } =================================================================== RCS file: /cvsroot/enlightenment/eterm/libast/src/url.c,v retrieving revision 1.17 retrieving revision 1.18 diff -u -3 -r1.17 -r1.18 --- url.c 4 Feb 2004 17:51:26 -0000 1.17 +++ url.c 5 Feb 2004 21:29:38 -0000 1.18 @@ -21,7 +21,7 @@ * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -static const char cvs_ident[] = "$Id: url.c,v 1.17 2004/02/04 17:51:26 mej Exp $"; +static const char cvs_ident[] = "$Id: url.c,v 1.18 2004/02/05 21:29:38 mej Exp $"; #ifdef HAVE_CONFIG_H # include <config.h> @@ -231,41 +231,6 @@ ASSERT_RVAL(!SPIF_URL_ISNULL(self), SPIF_NULL_TYPE(url)); tmp = spif_url_new_from_str(SPIF_STR(self)); - if (SPIF_STR_ISNULL(self->proto)) { - tmp->proto = SPIF_NULL_TYPE(str); - } else { - tmp->proto = spif_str_dup(self->proto); - } - if (SPIF_STR_ISNULL(self->user)) { - tmp->user = SPIF_NULL_TYPE(str); - } else { - tmp->user = spif_str_dup(self->user); - } - if (SPIF_STR_ISNULL(self->passwd)) { - tmp->passwd = SPIF_NULL_TYPE(str); - } else { - tmp->passwd = spif_str_dup(self->passwd); - } - if (SPIF_STR_ISNULL(self->host)) { - tmp->host = SPIF_NULL_TYPE(str); - } else { - tmp->host = spif_str_dup(self->host); - } - if (SPIF_STR_ISNULL(self->port)) { - tmp->port = SPIF_NULL_TYPE(str); - } else { - tmp->port = spif_str_dup(self->port); - } - if (SPIF_STR_ISNULL(self->path)) { - tmp->path = SPIF_NULL_TYPE(str); - } else { - tmp->path = spif_str_dup(self->path); - } - if (SPIF_STR_ISNULL(self->query)) { - tmp->query = SPIF_NULL_TYPE(str); - } else { - tmp->query = spif_str_dup(self->query); - } return tmp; } ------------------------------------------------------- The SF.Net email is sponsored by EclipseCon 2004 Premiere Conference on Open Tools Development and Integration See the breadth of Eclipse activity. February 3-5 in Anaheim, CA. http://www.eclipsecon.org/osdn _______________________________________________ enlightenment-cvs mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs