home *** CD-ROM | disk | FTP | other *** search
/ Amiga ISO Collection / AmigaUtilCD2.iso / Programming / C / SASC6571.LZX / source / cxovf.c < prev    next >
Encoding:
C/C++ Source or Header  |  1996-12-24  |  1.5 KB  |  45 lines

  1.  
  2. #include <exec/types.h>
  3. #include <intuition/intuition.h>
  4. #include <proto/exec.h>
  5. #include <proto/intuition.h>
  6. #include <string.h>
  7. void cxovf(void);
  8. void __exit(int);
  9.  
  10. extern struct IntuitionBase *IntuitionBase;
  11. extern char *_ProgramName;
  12.  
  13. static struct IntuiText Text2 = {-1,-1, /* pen numbers */
  14.                              0,         /* draw mode */
  15.                              14,14,     /* starting offsets */
  16.                              NULL,      /* text attribute pointer */
  17.                              NULL,
  18.                              NULL };
  19.  
  20. static struct IntuiText BodyText = {-1,-1,      /* pen numbers */
  21.                              0,         /* draw mode */
  22.                              4,4,       /* starting offsets */
  23.                              NULL,      /* text attribute pointer */
  24.                              "** Stack Overflow **",
  25.                              &Text2 };
  26.  
  27. static struct IntuiText ResponseText = {-1,-1,  /* pen numbers */
  28.                              0,         /* draw mode */
  29.                              4,4,       /* starting offsets */
  30.                              NULL,      /* text attribute pointer */
  31.                              "EXIT",
  32.                              NULL };
  33. void cxovf()
  34. {
  35. char    temp[80];
  36.  
  37. if (IntuitionBase == NULL)
  38.    IntuitionBase = (struct IntuitionBase *)
  39.                    OpenLibrary("intuition.library",0);
  40. memcpy(temp, _ProgramName, (long) _ProgramName[-1]);
  41. temp[(int) _ProgramName[-1]] = '\0';
  42. Text2.IText = temp;
  43. AutoRequest(NULL,&BodyText,NULL,&ResponseText,0,0,250,40);
  44. __exit(20);
  45. }