You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
749 B

  1. From b60b492602448b59aea194afd4991910d3613e5c Mon Sep 17 00:00:00 2001
  2. From: Cody Schafer <jmesmon@gmail.com>
  3. Date: Tue, 24 Apr 2012 04:33:13 -0500
  4. Subject: [PATCH 04/12] Fix transposition of memset parameters.
  5. ---
  6. utils.c | 2 +-
  7. 1 file changed, 1 insertion(+), 1 deletion(-)
  8. diff --git a/utils.c b/utils.c
  9. index afdeea8..31c6894 100644
  10. --- a/utils.c
  11. +++ b/utils.c
  12. @@ -222,7 +222,7 @@ char *red_inet_ntop(const struct sockaddr_in* sa, char* buffer, size_t buffer_si
  13. assert(buffer_size >= sizeof(placeholder));
  14. - memset(buffer, buffer_size, 0);
  15. + memset(buffer, 0, buffer_size);
  16. if (sa->sin_family == AF_INET) {
  17. retval = inet_ntop(AF_INET, &sa->sin_addr, buffer, buffer_size);
  18. port = ((struct sockaddr_in*)sa)->sin_port;
  19. --
  20. 1.9.1