1 /* UNIX SMBlib NetBIOS implementation
6 Copyright (C) Richard Sharpe 1996
11 This program is free software; you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation; either version 2 of the License, or
14 (at your option) any later version.
16 This program is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with this program; if not, write to the Free Software
23 Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
26 /* Error CLASS codes and etc ... */
28 #define SMBC_SUCCESS 0
29 #define SMBC_ERRDOS 0x01
30 #define SMBC_ERRSRV 0x02
31 #define SMBC_ERRHRD 0x03
32 #define SMBC_ERRCMD 0xFF
34 /* Define the protocol types ... */
36 #define SMB_P_Unknown -1 /* Hmmm, is this smart? */
38 #define SMB_P_CorePlus 1
39 #define SMB_P_DOSLanMan1 2
40 #define SMB_P_LanMan1 3
41 #define SMB_P_DOSLanMan2 4
42 #define SMB_P_LanMan2 5
43 #define SMB_P_DOSLanMan2_1 6
44 #define SMB_P_LanMan2_1 7
47 /* SMBlib return codes */
48 /* We want something that indicates whether or not the return code was a */
49 /* remote error, a local error in SMBlib or returned from lower layer ... */
50 /* Wonder if this will work ... */
51 /* SMBlibE_Remote = 1 indicates remote error */
52 /* SMBlibE_ values < 0 indicate local error with more info available */
53 /* SMBlibE_ values >1 indicate local from SMBlib code errors? */
55 #define SMBlibE_Success 0
56 #define SMBlibE_Remote 1 /* Remote error, get more info from con */
57 #define SMBlibE_BAD -1
58 #define SMBlibE_LowerLayer 2 /* Lower layer error */
59 #define SMBlibE_NotImpl 3 /* Function not yet implemented */
60 #define SMBlibE_ProtLow 4 /* Protocol negotiated does not support req */
61 #define SMBlibE_NoSpace 5 /* No space to allocate a structure */
62 #define SMBlibE_BadParam 6 /* Bad parameters */
63 #define SMBlibE_NegNoProt 7 /* None of our protocols was liked */
64 #define SMBlibE_SendFailed 8 /* Sending an SMB failed */
65 #define SMBlibE_RecvFailed 9 /* Receiving an SMB failed */
66 #define SMBlibE_GuestOnly 10 /* Logged in as guest */
67 #define SMBlibE_CallFailed 11 /* Call remote end failed */
68 #define SMBlibE_ProtUnknown 12 /* Protocol unknown */
69 #define SMBlibE_NoSuchMsg 13 /* Keep this up to date */