// DIE's signature file
// Author: hypn0 <hypn0@mail.ru>

init("extender","Borland RTM DPMI loader");

function getBLVersion()
{
    var sResult="";

    var nOffset=MSDOS.findString(0,MSDOS.getSize(),"RTM loader version")

    if(nOffset!=-1)
    {
        sResult=MSDOS.getString(nOffset+19);
        sResult=sResult.substr(0,sResult.indexOf(' '));
    }

    return sResult;
}

function detect(bShowType,bShowVersion,bShowOptions)
{
    if(MSDOS.compareEP("b8....8ed8b8....bb....8ed08be38926....0626......8ec0263b......74..e9"))
    {
        sVersion="1.0-1.5";
        bDetected=1;
    }

    if(bDetected)
    {
        var sBL=getBLVersion();
        if(sBL!="")
        {
            sVersion=sBL;
        }
    }

    return result(bShowType,bShowVersion,bShowOptions);
}
