www.pudn.com > czxtsycx1.zip > GINT8.C


void interrupt gint8() 
 {   
    oldhandler(); 
    asm cli 
    inregs.h.ah=0x34; 
    intdosx(&inregs,&outregs,&segs); 
    indos=(char far *)(((long)(segs.es)<<16)+outregs.x.bx); 
    if (*indos) goto g_ret; 
    asm mov al,0x0B 
    asm out 0x20,al 
    asm nop 
    asm in al,0x20 
    asm and al,0x0fe 
    asm jnz g_ret 
    time_count =time_count - 1; 
    if ( time_sch == 0 ) goto g_ret ; 
    if (time_count>=1) goto g_ret; 
    time_sch=0; 
    asm      pop word ptr r_bp 
    asm      pop word ptr r_di 
    asm      pop word ptr r_si 
    asm      pop word ptr r_ds 
    asm      pop word ptr r_es 
    asm      pop word ptr r_dx 
    asm      pop word ptr r_cx 
    asm      pop word ptr r_bx 
    asm      pop word ptr r_ax 
    asm      pop word ptr r_ip 
    asm      pop word ptr r_cs 
    asm      pop word ptr r_flag 
    asm push word ptr gsch_seg 
    asm push word ptr gsch_off 
    asm ret; 
 g_ret: 
    asm sti; 
 } 
void ggret() 
  { 
    setvect(INTERRUPT,oldhandler); 
    printf("\n   Exit from gsch()"); 
    exit(0); 
  }