From: | Stephen Illingworth |
Date: | 01 Aug 2000 at 21:42:29 |
Subject: | Re: Why doesn't this code work? |
Hello Donald
On 31-Jul-00, you wrote:
> About two and a half years ago I decided to write a small database to
> test my programming skills. I based it on coursework done in Borland
> Turbo C on the PC at college. I decided to appraoch the project as
> though it were a professional contract and drew up specifications and
> peformed unbelievebly extensive testing. I implemented the code in a
> modular fashion, writing and testing each function individually and
> with all of the others. To finish the program I performed a full
> program test - that's when it crashed.
>
> I assumed (and still do assume based on my own debugging) that the
> crash happens when the program runs and attempts to load its data
> file. When the program was in its early stages, I created seperate
> create-file and read-file programs which were then incorporated into
> the main program as save and load functions respectively with no
> changes whatsoever. These original programs have always worked
> perfectly.
>
> When PupilDbase is run under OS3.0 it will freeze and cause a system
> reset during or after initial loading. Curiously, all three programs
> work fine under OS3.5 with not the slightest problem.
>
> If you're still awake after all that then you'll be glad to know that
> I've got to the point - I can't figure out why the main file crashes.
>
> I've supplied all the code and executables in my file attachment.
> Could some of you test the program and see if you know why it crashes
> (sorry, the code is uncommented but should be fairly obvious to
> understand). Don't forget to change the paths for loading and saving
> the data file to wherever you are running the program from.
>
> Any help appreciated.
>
The first question I have to ask is, what compiler are you using? There
isn't a compiler that I've ever come across that will handle that code.
Steve