home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / World_Of_Computer_Software-02-386-Vol-2of3.iso / b / bm_rm.zip / GETSWCHR.ASM < prev    next >
Assembly Source File  |  1989-08-02  |  1KB  |  38 lines

  1. ;getswchr() - Return the current system switch character (normally '/')
  2. ;
  3. ;Syntax: char getswchr (void);
  4. ;
  5. ;Requires DOS 2.0 or above.  An undocumented DOS call is used.
  6. ;
  7. ;Copyright (C) 1989 Brian B. McGuinness
  8. ;                   15 Kevin Road
  9. ;                   Scotch Plains, NJ 07076
  10. ;
  11. ;This function is free software; you can redistribute it and/or modify it under 
  12. ;the terms of the GNU General Public License as published by the Free Software 
  13. ;Foundation; either version 1, or (at your option) any later version.
  14. ;
  15. ;This function is distributed in the hope that it will be useful, but WITHOUT 
  16. ;ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 
  17. ;FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more 
  18. ;details.
  19. ;
  20. ;You should have received a copy of the GNU General Public License along with 
  21. ;this function; if not, write to the Free Software Foundation, Inc., 675 Mass 
  22. ;Ave, Cambridge, MA 02139, USA.
  23. ;
  24. ;Version 1.0          July, 1989          MASM 5.1
  25.  
  26.         DOSSEG
  27.         .MODEL small,C 
  28.         .CODE
  29.  
  30. getswchr proc uses dx
  31.         mov ax,3700H    ;Get current switch char in DL.
  32.         int 21H
  33.         xor ax,ax       ;Return it in AX, according to C calling conventions.
  34.         mov al,dl
  35.         ret
  36. getswchr endp
  37.         end
  38.