Home My Page Projects Code Snippets Project Openings SML/NJ
Summary Activity Forums Tracker Lists Tasks Docs Surveys News SCM Files

SCM Repository

[smlnj] View of /sml/trunk/src/runtime/c-libs/smlnj-sockets/gethostbyaddr.c
ViewVC logotype

View of /sml/trunk/src/runtime/c-libs/smlnj-sockets/gethostbyaddr.c

Parent Directory Parent Directory | Revision Log Revision Log


Revision 249 - (download) (as text) (annotate)
Sat Apr 17 18:57:03 1999 UTC (21 years, 2 months ago) by monnier
Original Path: sml/branches/SMLNJ/src/runtime/c-libs/smlnj-sockets/gethostbyaddr.c
File size: 728 byte(s)
version 110.16
/* gethostbyaddr.c
 *
 * COPYRIGHT (c) 1995 AT&T Bell Laboratories.
 */

#include "ml-unixdep.h"
#include "sockets-osdep.h"
#include INCLUDE_TYPES_H
#include INCLUDE_SOCKET_H
#include INCLUDE_IN_H
#include <netdb.h>
#include "ml-base.h"
#include "ml-values.h"
#include "ml-objects.h"
#include "ml-c.h"
#include "cfun-proto-list.h"
#include "sock-util.h"

/* _ml_NetDB_gethostbyaddr
 *     : addr -> (string * string list * addr_family * addr list) option
 */
ml_val_t _ml_NetDB_gethostbyaddr (ml_state_t *msp, ml_val_t arg)
{
    ASSERT (sizeof(struct in_addr) == OBJ_LEN(arg));

    return _util_NetDB_mkhostent (
	msp,
	gethostbyaddr (STR_MLtoC(arg), sizeof(struct in_addr), AF_INET));

} /* end of _ml_NetDB_gethostbyaddr */

root@smlnj-gforge.cs.uchicago.edu
ViewVC Help
Powered by ViewVC 1.0.0