home *** CD-ROM | disk | FTP | other *** search
/ Microsoft Programmer's Library 1.3 / Microsoft-Programers-Library-v1.3.iso / sampcode / dos_ency / section5 / fxn33h.asm < prev    next >
Encoding:
Assembly Source File  |  1988-08-11  |  1.1 KB  |  23 lines

  1.         ;************************************************************;
  2.         ;                                                            ;
  3.         ;          Function 33H: Get/Set Control-C Check Flag        ;
  4.         ;                                                            ;
  5.         ;          int controlC(func,state)                          ;
  6.         ;              int func,state;                               ;
  7.         ;                                                            ;
  8.         ;          Returns current state of Ctrl-C flag.             ;
  9.         ;                                                            ;
  10.         ;************************************************************;
  11.  
  12. cProc   controlC,PUBLIC
  13. parmB   func
  14. parmB   state
  15. cBegin
  16.         mov     al,func         ; Get set/reset function.
  17.         mov     dl,state        ; Get new value if present.
  18.         mov     ah,33h          ; MS-DOS ^C check function.
  19.         int     21h             ; Call MS-DOS.
  20.         mov     al,dl           ; Return current state.
  21.         cbw                     ; Clear high byte of return value.
  22. cEnd
  23.