summaryrefslogtreecommitdiff
path: root/src/misc.c
diff options
context:
space:
mode:
authorgeniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-03-07 20:03:07 +0000
committergeniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b <geniusdex geniusdex@31f1291d-b8d6-0310-a050-a5561fc1590b@5417fbe8-f217-4b02-8779-1006273d7864>2005-03-07 20:03:07 +0000
commit2f44331e17a1673580725cf9fb097b82e6393502 (patch)
treef075d7a978bc032ee79739a5a93d2b22ca593714 /src/misc.c
parent5ae91e374c40200c8efb291fa7a5086ef76dbe04 (diff)
BUILD : 1.7.8 (606) BUGS : NOTES : Removed proxy detector code from the core, threads stuff still there. Needs good testing
git-svn-id: svn://svn.anope.org/anope/trunk@606 31f1291d-b8d6-0310-a050-a5561fc1590b git-svn-id: http://anope.svn.sourceforge.net/svnroot/anope/trunk@454 5417fbe8-f217-4b02-8779-1006273d7864
Diffstat (limited to 'src/misc.c')
-rw-r--r--src/misc.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/misc.c b/src/misc.c
index cf7ac593e..147895e9b 100644
--- a/src/misc.c
+++ b/src/misc.c
@@ -1147,4 +1147,13 @@ char *stripModePrefix(const char *str) {
return NULL;
}
+/* Equivalent to inet_ntoa */
+
+void ntoa(struct in_addr addr, char *ipaddr, int len)
+{
+ unsigned char *bytes = (unsigned char *) &addr.s_addr;
+ snprintf(ipaddr, len, "%u.%u.%u.%u", bytes[0], bytes[1], bytes[2],
+ bytes[3]);
+}
+
/* EOF */