TutGetNodeName get the name of the current node
name_return
storage for node name
String containing node name.
None
TutGetNodeName is a convenience function that gets the name of the current node. On UNIX, TutGetNodeName uses either the uname or gethostname function. On Windows, TutGetNodeName uses the WinSock gethostname
function. On MVS, TutGetNodeName uses the IBM TCP/IP gethostname
function. If that fails, it uses the SMF ID. On OpenVMS TutGetNodeName translates the logical SYS$NODE
and removes the trailing double colon.
If TutGetNodeName cannot obtain the node name from the operating system, it stores UNKNOWN
in name_return
.
There is no way to know ahead of time how much storage is needed for name_return
.
The value of name_return
cannot be NULL
. Storage for name_return
must be managed by the caller.
None
This example prints the name of the current node:
TIBCO SmartSockets™ Utilities Software Release 6.8, July 2006 Copyright © TIBCO Software Inc. All rights reserved www.tibco.com |