2 * $Id: dsi_init.c,v 1.10 2009-11-05 14:38:08 franklahm Exp $
4 * Copyright (c) 1997 Adrian Sun (asun@zoology.washington.edu)
5 * All rights reserved. See COPYRIGHT.
10 #endif /* HAVE_CONFIG_H */
15 #include <atalk/dsi.h>
16 #include "dsi_private.h"
18 DSI *dsi_init(AFPObj *obj, const char *hostname, const char *address, const char *port)
22 if ((dsi = (DSI *)calloc(1, sizeof(DSI))) == NULL)
25 dsi->attn_quantum = DSI_DEFQUANT;
26 dsi->server_quantum = obj->options.server_quantum;
27 dsi->dsireadbuf = obj->options->dsireadbuf;
29 /* currently the only transport protocol that exists for dsi */
30 if (dsi_tcp_init(dsi, hostname, address, port) != 0) {
38 void dsi_setstatus(DSI *dsi, char *status, const size_t slen)
41 dsi->statuslen = slen;