home *** CD-ROM | disk | FTP | other *** search
/ NetNews Offline 2 / NetNews Offline Volume 2.iso / news / comp / sys / amiga / programmer / 5189 < prev    next >
Encoding:
Text File  |  1996-08-05  |  1.2 KB  |  40 lines

  1. Newsgroups: comp.sys.amiga.programmer
  2. Path: mozart.unx.sas.com!sassek
  3. From: sassek@unx.sas.com (Steve Krueger)
  4. Subject: Re: Ceck out this bug. What the *** is SASC/6.56 doing?
  5. Sender: news@unx.sas.com (Noter of Newsworthy Events)
  6. Message-ID: <sassek.826554207@sas.com>
  7. Date: Mon, 11 Mar 1996 14:23:27 GMT
  8. X-Nntp-Posting-Host: wonka.unx.sas.com
  9. References: <1120.6643T91T406@login.eunet.no>
  10. Organization: SAS Institute Inc.
  11.  
  12. patrick.hanevold@login.eunet.no (Patrick Hanevold) writes:
  13.  
  14.  
  15. >Can anyone explain this? Try compiling this with a SC default SCOPTIONS
  16. >file, and start it from CLI. It only crashes from CLI.
  17. >This one was REALY fun finding. Dealyed ChunkyScreen a couple of days.
  18.  
  19. >void main(void)
  20. >{
  21. >    int     x,y,n;
  22. >    UBYTE   Buffer[ScreenWidth];
  23. >    ULONG   Palette[256*3+2];           // This one causes the bug.
  24.  
  25. >    struct  Screen  *Scr=OpenScreenTags(NULL,
  26. >        SA_Width,           320,
  27. >        SA_Height,          256,
  28. >        SA_Depth,           8,
  29. >        TAG_END);
  30.  
  31. >    CloseScreen(Scr);
  32. >}
  33.  
  34. You are probably running out of stack. With a standard 4k stack,
  35. after the prolog of main(), you only have 640 bytes of stack left.
  36. Apparently not enough for OpenScreenTags(). The program runs
  37. fine with a 20k stack.
  38.  
  39. sk
  40.