summaryrefslogtreecommitdiffstats
path: root/private/nw/nwscript/version.c
blob: b4ce000d6cccfd9415a6b8f0f4aa2cce659f4ee3 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
/*************************************************************************
*
*  VERSION.C
*
*  Shell version information
*
*  Copyright (c) 1995 Microsoft Corporation
*
*  $Log:   N:\NT\PRIVATE\NW4\NWSCRIPT\VCS\VERSION.C  $
*  
*     Rev 1.2   10 Apr 1996 14:24:08   terryt
*  Hotfix for 21181hq
*  
*     Rev 1.2   12 Mar 1996 19:56:28   terryt
*  Relative NDS names and merge
*  
*     Rev 1.1   22 Dec 1995 14:27:10   terryt
*  Add Microsoft headers
*  
*     Rev 1.0   15 Nov 1995 18:08:18   terryt
*  Initial revision.
*  
*     Rev 1.1   26 Jul 1995 14:17:24   terryt
*  Clean up comments
*  
*     Rev 1.0   15 May 1995 19:11:12   terryt
*  Initial revision.
*  
*************************************************************************/

#include <stdio.h>
#include <direct.h>
#include <time.h>
#include <stdlib.h>

#include <nt.h>
#include <ntrtl.h>
#include <nturtl.h>
#include <windows.h>

#include "nwscript.h"


/*
 *  MSDOS is not neccessarily the best thing to put out,
 *  maybe Windows_NT, NT or NTDOS.  The OS_VERSION is also a problem.
 *  The script variables don't neccessarily have to match the DOS variables.
 *
 *  The shell version numbers may change with 4.X support.
 */
 
#define CLIENT_ID_STRING "MSDOS\0V5.00\0IBM_PC\0IBM"
#define CLIENT_SHELL_MAJOR  0x03
#define CLIENT_SHELL_MINOR  0x1a
#define CLIENT_SHELL_NUMBER 0x00


void
NTGetVersionOfShell( char * buffer,
                     unsigned char * shellmajor,
                     unsigned char * shellminor,
                     unsigned char * shellnum )
{
    *shellmajor = CLIENT_SHELL_MAJOR;
    *shellminor = CLIENT_SHELL_MINOR;
    *shellnum = CLIENT_SHELL_NUMBER;
    memcpy( buffer, CLIENT_ID_STRING, 40 );
}