Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Posting-Version: version B 2.10.2 9/3/84; site sesame.UUCP Path: utzoo!linus!philabs!cmcl2!harvard!talcott!sesame!slerner From: slerner@sesame.UUCP (Simcha-Yitzchak Lerner) Newsgroups: net.micro.pc Subject: Re: Sidekick vs. Microsoft C Message-ID: <353@sesame.UUCP> Date: Sun, 13-Oct-85 11:48:27 EDT Article-I.D.: sesame.353 Posted: Sun Oct 13 11:48:27 1985 Date-Received: Tue, 15-Oct-85 07:39:53 EDT References: <962@vax2.fluke.UUCP> Distribution: net Organization: Lotus Development Corp Lines: 46 > > <> > > Does anyone know why memory resident programs such as Sidekick won't come up > when the following program, compiled with Microsoft C (3.0), is being run? > > main () { > char string[80]; > while (1) { > puts("Enter a terminated line\n"); > gets(string); > } > } > > Sidekick is loaded, the above program is executed, and then Ctrl-ALT is pressed > to invoke Sidekick. The computer emits 5 slow beeps, and then continues. A > similar version of the program, (using fgets(string,80,stdin)), compiled with > C86 did the same thing. > > Any ideas? > -- > Bruce T. White > John Fluke Mfg. Co., Inc. > {uw-beaver,decvax!microsof,ucbvax!lbl-csam,allegra,ssc-vax}!fluke!sota I would *guess* that what is going on has to do with the fact that many memory resident programs will not activate themselves when a DOS call is active. (They will retry several times, beep (sometimes) and give up). I suspect that a DOS call to get a char (and wait for it if not available) is being used by the above routine, and Sidekick sees that a DOS call is active, and not wanting to crash the system (DOS is not reentrant), beeps and gives up. If you can code useing functions that get a char. only if available, you should have a chance to get Sidekick to load. -- Opinions expressed are public domain, and do not belong to Lotus Development Corp. ---------------------------------------------------------------- Simcha-Yitzchak Lerner {genrad|ihnp4|ima}!wjh12!talcott!sesame!slerner {cbosgd|harvard}!talcott!sesame!slerner talcott!sesame!slerner@harvard.ARPA