From: "OiSyN" Newsgroups: comp.os.msdos.djgpp Subject: Re: a VERY difficult problem Date: Fri, 17 Sep 1999 19:55:34 +0200 Message-ID: <937590686.28337.0.pluto.d4ee0fa5@news.demon.nl> References: <937519527 DOT 589 DOT 0 DOT pluto DOT d4ee0fa5 AT news DOT demon DOT nl> <136f266c DOT bebfc4f7 AT usw-ex0103-020 DOT remarq DOT com> NNTP-Posting-Host: x-project.demon.nl X-NNTP-Posting-Host: x-project.demon.nl:212.238.15.165 X-Trace: news.demon.nl 937590686 pluto:28337 NO-IDENT x-project.demon.nl:212.238.15.165 X-Complaints-To: abuse AT demon DOT net X-Newsreader: Microsoft Outlook Express 4.72.3110.5 X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3 Lines: 29 To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com >I think you have a stack problem. I don't know how you >hooked the timer interrupt, but remember that the original >timer handler does many things. If you call your handler >directly you might skip all that. Do you keep a seperate >stack for every thread? > >Clemens > Yes, I allocate a piece of memory for each thread that is created (in my simple program I used 10k of mem per thread. It has only a simple loop, so that should be more than enough) I also initiated the flags. The first time, I set them to zero, and the next thing that happened was that the interrupt flag was cleared. So it got stuck in an infinite loop, because thread switching didn't work anymore. I found out and thought that was the problem. But it isn't. Well, maybe, Now, I initiate the flags to 0x3202, which are the same flags on DJGPP startup. Do you know where I can get full documentation about the flags register? Or do you know what else could be the problem? thanx! Sylvester Hesp oisyn AT x-project DOT demon DOT nl