socket.m: Replace inet_{ntop,pton} with own impl

Not all OSes supported by ObjFW provide them.