<html><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hi,<div><br class="webkit-block-placeholder"></div><div>I saw these definitions in lispworks.lisp:</div><div><br class="webkit-block-placeholder"></div><div><div>#+win32</div><div>(fli:register-module "ws2_32")</div><div><br class="webkit-block-placeholder"></div><div>(fli:define-foreign-function (get-host-name-internal "gethostname" :source)</div><div> ((return-string (:reference-return (:ef-mb-string :limit 257)))</div><div> (namelen :int))</div><div> :lambda-list (&aux (namelen 256) return-string)</div><div> :result-type :int</div><div> #+win32 :module</div><div> #+win32 "ws2_32")</div><div><br class="webkit-block-placeholder"></div><div>(defun get-host-name ()</div><div> (multiple-value-bind (retcode name)</div><div> (get-host-name-internal)</div><div> (when (= 0 retcode)</div><div> name)))</div><div><br class="webkit-block-placeholder"></div><div>What's the usage of GET-HOST-NAME? Can we use CL:MACHINE-INSTANCE instead? I think they have the same effect:</div><div><br class="webkit-block-placeholder"></div><div><div>CL-USER 4 > (machine-instance)</div><div>"binghe-mac.local"</div><div><br class="webkit-block-placeholder"></div><div>CL-USER 5 > (usocket::get-host-name)</div><div>"binghe-mac.local"</div><div><br class="webkit-block-placeholder"></div><div>Thanks,</div><div><br class="webkit-block-placeholder"></div><div>Chun TIAN (binghe)</div><div><br class="webkit-block-placeholder"></div></div></div></body></html>