zookeeper-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From nkalmar <...@git.apache.org>
Subject [GitHub] zookeeper pull request #559: ZOOKEEPER-3079: avoid unsafe use of sprintf(3)
Date Wed, 04 Jul 2018 15:35:14 GMT
Github user nkalmar commented on a diff in the pull request:

    https://github.com/apache/zookeeper/pull/559#discussion_r200161012
  
    --- Diff: src/c/src/zookeeper.c ---
    @@ -4357,7 +4357,7 @@ int zoo_add_auth(zhandle_t *zh,const char* scheme,const char* cert,
     static const char* format_endpoint_info(const struct sockaddr_storage* ep)
     {
         static char buf[128] = { 0 };
    -    char addrstr[128] = { 0 };
    +    char addrstr[INET6_ADDRSTRLEN] = { 0 };
    --- End diff --
    
    Isn't this by default 46 as per POSIX? I don't see this overridden in ZK.


---

Mime
View raw message