;;;; Programmer: Kevin M. Rosenberg with excerpts from portableaserve
;;;; Date Started: Jun 2003
;;;;
-;;;; $Id: sockets.lisp,v 1.5 2003/07/21 00:52:56 kevin Exp $
+;;;; $Id$
;;;; *************************************************************************
(in-package #:kmrcl)
"Convert from dotted string to 32-bit integer."
(declare (string dotted))
(if errorp
- (let ((ll (string-tokens (substitute #\Space #\. dotted))))
+ (let ((ll (delimited-string-to-list dotted #\.)))
(+ (ash (first ll) 24) (ash (second ll) 16)
(ash (third ll) 8) (fourth ll)))
(ignore-errors
- (let ((ll (string-tokens (substitute #\Space #\. dotted))))
- (+ (ash (first ll) 24) (ash (second ll) 16)
- (ash (third ll) 8) (fourth ll))))))
+ (let ((ll (delimited-string-to-list dotted #\.)))
+ (+ (ash (first ll) 24) (ash (second ll) 16)
+ (ash (third ll) 8) (fourth ll))))))
#+sbcl
(defun ipaddr-to-hostname (ipaddr &key ignore-cache)