home *** CD-ROM | disk | FTP | other *** search
/ DP Tool Club 12 / CD_ASCQ_12_0294.iso / vrac / pclcjs.zip / GETBANV.C < prev    next >
C/C++ Source or Header  |  1993-04-29  |  684b  |  33 lines

  1.  
  2. #include <dos.h>
  3. #include <stdio.h>
  4. #include <stdlib.h>
  5. #include <string.h>
  6.  
  7. /*
  8.  * Author: Scott Sharkey                  Date: 03/20/90
  9.  *
  10.  * This program is released into the public domain, and no warranties
  11.  * of any kind apply.  You may do whatever you wish with this code, but
  12.  * please leave this comment in your new code.
  13.  *
  14.  * Note: Turbo C 2.0 and/or MSC 5.1 should work.
  15.  *
  16.  */
  17.  
  18.  
  19. int get_banv(void)
  20.  
  21. {
  22.     char far* far* pch;
  23.     int  j;
  24.  
  25.     for (j = 0x60; j < 0x67; j++ ) {
  26.         pch = (char far* far*) (0x4 * j);
  27.         if ((*(*pch - 4) == 'B') && (*(*pch - 3) == 'A') && (*(*pch - 2) == 'N') && (*(*pch - 1) == 'V') ) {
  28.             return(j);
  29.         }
  30.     }
  31.     return(0);
  32. }
  33.