2000-05-06 21:34:20 +02:00
|
|
|
/****************************************************************/
|
|
|
|
/* */
|
|
|
|
/* network.c */
|
|
|
|
/* DOS-C */
|
|
|
|
/* */
|
|
|
|
/* Networking Support functions */
|
|
|
|
/* */
|
|
|
|
/* Copyright (c) 1995, 1999 */
|
|
|
|
/* James Tabor */
|
|
|
|
/* All Rights Reserved */
|
|
|
|
/* */
|
|
|
|
/* This file is part of DOS-C. */
|
|
|
|
/* */
|
|
|
|
/* DOS-C is free software; you can redistribute it and/or */
|
|
|
|
/* modify it under the terms of the GNU General Public License */
|
|
|
|
/* as published by the Free Software Foundation; either version */
|
|
|
|
/* 2, or (at your option) any later version. */
|
|
|
|
/* */
|
|
|
|
/* DOS-C is distributed in the hope that it will be useful, but */
|
|
|
|
/* WITHOUT ANY WARRANTY; without even the implied warranty of */
|
|
|
|
/* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See */
|
|
|
|
/* the GNU General Public License for more details. */
|
|
|
|
/* */
|
|
|
|
/* You should have received a copy of the GNU General Public */
|
|
|
|
/* License along with DOS-C; see the file COPYING. If not, */
|
|
|
|
/* write to the Free Software Foundation, 675 Mass Ave, */
|
|
|
|
/* Cambridge, MA 02139, USA. */
|
|
|
|
/****************************************************************/
|
|
|
|
|
|
|
|
#include "portab.h"
|
|
|
|
#include "globals.h"
|
|
|
|
|
|
|
|
#ifdef VERSION_STRINGS
|
2001-11-18 15:01:12 +01:00
|
|
|
static BYTE *RcsId =
|
|
|
|
"$Id$";
|
2000-05-06 21:34:20 +02:00
|
|
|
#endif
|
|
|
|
|
2001-11-18 00:26:45 +01:00
|
|
|
/* see RBIL D-2152 and D-215D06 before attempting
|
|
|
|
to change these two functions!
|
|
|
|
*/
|
|
|
|
UWORD get_machine_name(BYTE FAR * netname)
|
|
|
|
{
|
|
|
|
fmemcpy(netname, &net_name, 16);
|
|
|
|
return (NetBios);
|
|
|
|
}
|
|
|
|
|
|
|
|
VOID set_machine_name(BYTE FAR * netname, UWORD name_num)
|
|
|
|
{
|
|
|
|
NetBios = name_num;
|
|
|
|
fmemcpy(&net_name, netname, 15);
|
|
|
|
net_set_count++;
|
|
|
|
}
|
|
|
|
|
2004-04-21 02:53:45 +02:00
|
|
|
int network_redirector_fp(unsigned cmd, void far *s)
|
|
|
|
{
|
2004-04-21 04:01:56 +02:00
|
|
|
return (int)network_redirector_mx(cmd, s, 0);
|
2004-04-21 02:53:45 +02:00
|
|
|
}
|
|
|
|
|
2004-04-20 22:25:26 +02:00
|
|
|
int network_redirector(unsigned cmd)
|
|
|
|
{
|
|
|
|
return network_redirector_fp(cmd, NULL);
|
|
|
|
}
|
2004-04-21 19:40:12 +02:00
|
|
|
|