chiark / gitweb /
subnet_to_string: Do not allocate
[secnet.git] / ipaddr.c
index 6d0b02ad0b1f61c18c845de917b448985d972891..d23317c90dd1308b6d5a4c53fec0ec89bcdbd217 100644 (file)
--- a/ipaddr.c
+++ b/ipaddr.c
@@ -358,7 +358,7 @@ string_t subnet_to_string(struct subnet sn)
     uint8_t a,b,c,d;
     string_t s;
 
-    s=safe_malloc(19,"subnet_to_string");
+    s=ipaddr_getbuf();
     a=addr>>24;
     b=addr>>16;
     c=addr>>8;