Program reset PC in DOS, pascal

Delphi & Pascal (česká wiki)
Přejít na: navigace, hledání
Category: Source in Pascal

Program: Reset.pas
File exe: Reset.exe

Impossible to be used in Windows, it serves to perform the "soft reset of the PC" in DOS. You may like the length of the source code. Out of 9 lines, 4 are unnecessary.
{ RESET.PAS                 Copyright (c) TrSek alias Zdeno Sekerak }
{ Resetne PC - Nefunguje pod Win 9x/NT/2K                           }
{                                                                   }
{ Datum:07.12.1995                             http://www.trsek.com }
 
program Reset_pocitaca;
var
  no_boot:procedure;
  smer:pointer;
 
begin
  writeln('Za okamih prebehne reset pocitaca.');
  smer:=Ptr($FFFF,$0);
  @no_boot:=smer;
  no_boot;
end.