•  Back 
  •  Notes about MagiC's 3D-look 
  •  Index 
  •  Tree View 
  •  Cross references 
  •  Help page 
  •  Show info about hypertext 
  •  View a new file 
Topic       : TOS - The Operating System
Author      : 
Version     : tos.hyp (December 19, 2008)
Subject     : Programmieren/Atari
Nodes       : 3010
Index Size  : 93790
HCP-Version : 5
Compiled on : Atari
@charset    : atarist
@lang       : 
@default    : Title
@help       : 
@options    : +g -i -s +x +zz -t4
@width      : 70
View Ref-File11.5.12  Test for MagiC                                            TOS

/*  The following code tess whether MagiC is installed, and returns
    one of the following values:

    -1 = No MagiC present
    -2 = MagiC installed, but MagiC-AES inactive, i.e. MagiC is only
         being used as a fast filesystem
    >0 = MagiC present and MagiC-AES active. The return value contains
         the BCD-coded version number  */

GLOBAL WORD InqMagX (VOID)
{
    MAGX_COOKIE *cv;

    if (get_cookie ("MagX", (LONG) &cv))
    {
        if (cv->aesvars)
            return (cv->aesvars->version);
        else
           return (-2);
    }
    else
       return (-1);
} /* InqMagX */

Note: Programs launched from the AUTO folder can not obtain MagiC's 
version number with the aid of this routine, since the AES is not yet 
initialized at boot-time. In this case one should fall back on the 
function DoMagixAESVars.

See also: Cookie jar   Cookie and XBRA list