diff options
author | Russell Bryant <russell@russellbryant.com> | 2006-07-21 17:31:28 +0000 |
---|---|---|
committer | Russell Bryant <russell@russellbryant.com> | 2006-07-21 17:31:28 +0000 |
commit | ca9ba719b6f4ef598bc3dc71bdee05d11d0c7687 (patch) | |
tree | 9a03027276c525f44c08eb5dc4d7b9035fa697c9 /acl.c | |
parent | 1861dcdff5666cbac27288f7bdfdf40104d29d4d (diff) |
Merge a new implementation of ast_inet_ntoa, our thread safe replacement for
inet_ntoa, which uses thread specific data (aka thread local storage) instead
of stack allocatted buffers to store the result.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@38042 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'acl.c')
-rw-r--r-- | acl.c | 7 |
1 files changed, 3 insertions, 4 deletions
@@ -208,10 +208,9 @@ int ast_apply_ha(struct ast_ha *ha, struct sockaddr_in *sin) char iabuf[INET_ADDRSTRLEN]; char iabuf2[INET_ADDRSTRLEN]; /* DEBUG */ - ast_log(LOG_DEBUG, - "##### Testing %s with %s\n", - ast_inet_ntoa(iabuf, sizeof(iabuf), sin->sin_addr), - ast_inet_ntoa(iabuf2, sizeof(iabuf2), ha->netaddr)); + ast_copy_string(iabuf, ast_inet_ntoa(sin->sin_addr), sizeof(iabuf)); + ast_copy_string(iabuf2, ast_inet_ntoa(ha->netaddr), sizeof(iabuf2)); + ast_log(LOG_DEBUG, "##### Testing %s with %s\n", iabuf, iabuf2); /* For each rule, if this address and the netmask = the net address apply the current rule */ if ((sin->sin_addr.s_addr & ha->netmask.s_addr) == ha->netaddr.s_addr) |