Re: loopy loop execution
>
>
> posted by: Matt Lewis <matthewwalkerlewis at gmail.com>
>
> Kat wrote:
> >
> >
> > and the program exits the while loop, and where TheWebPage was
> > pronounced to be 16 chars long by this line:
> >
> > puts(1,sprintf("%d",length(TheWebPage))&" -- ")
> >
> > TheRadarPic is now 0 bytes long, said by this line:
> >
> > puts(1,sprintf("%d",length(TheRadarPic))&"\n")
> >
> > So my questions are, how is it getting out of the while loop?, and
> > how is the length being changed? This is an intermittant problem, it
> > doesn't always do this, it's like a once-a-day thing.
> >
>
> I guess my first suspicion would be that there's a disconnect between
> TheWebPage and upperTheWebPage.
upperTheWebPage = upper(TheWebPage)
> Maybe try something like: }}}
<eucode>
> printf(1, "TheWebPage %d upperTheWebPage %d TheRadarPic %d\n",
> { length(TheWebPage), length(upperTheWebPage), length(TheRadarPic)
> })
> </eucode>
{{{
> Also, I'm assuming that you've got }}}
<eucode>while 1 do</eucode>
{{{
(or the
> equivalent) as the while loop.
It's
while equal(TheWebPage,"") do
and the bottom of the loop sets TheWebPage back to "" if it hasn't
exited already. So does the start of the loop, and the line before
the loop. Full code for the loop is at
http://designerthinking.com/temp/whiledemo.e
The same loop is in use in other apps, which would crash horribly if
it made the same error as this app is doing, same as this app is
crashing.
Kat
|
Not Categorized, Please Help
|
|