```edbrowse-dev - development list for edbrowse
help / color / mirror / Atom feed```
```* [Edbrowse-dev] infinite loop
@ 2017-01-27 12:43 Karl Dahlke
0 siblings, 0 replies; 5+ messages in thread
From: Karl Dahlke @ 2017-01-27 12:43 UTC (permalink / raw)
To: Edbrowse-dev

This site runs forever, but not like the others, not infinite recursion that blows up a stack, it just seems to churn.

http://www.thegatewaypundit.com/2016/11/az-indian-tribe-controls-75-miles-border-wont-allow-trump-wall-land-video

Karl Dahlke

```* [edbrowse-dev] infinite loop
@ 2019-09-10  8:13 Karl Dahlke
0 siblings, 0 replies; 5+ messages in thread
From: Karl Dahlke @ 2019-09-10  8:13 UTC (permalink / raw)
To: edbrowse-dev

This is so absurd that I just have to give up and move on to something else.

https://kutv.com/news/offbeat/vegan-sues-neighbors-over-smell-of-barbecued-meat-in-their-backyards
references
which contains this code, slightly cleaned up for readability.

setCookie: function  (a, w1, w2, extra) {
extra = extra || {};
var w = w1 + '=' + w2;
var c = 0;
for (var i = 0, l = a['length']; i < l; i++) {
var e = a[i];
w += '; ' + e;
var f = a[e];
a['push'](f);
l = a['length'];
if (f !== !![]) {
w += '=' + f;
}
}
}

Then invoked like this.

As long as it is called with a nonzero array, it pushes undefined onto the array forever,
incrementing l and i forever, an infinite loop.
Is it not?

Even if it wasn't, the code makes no sense.
c is set but not used.
The whol calculation puts cookie in a local object that is then thrown away.
WTF
I wonder if this site comes up in a real browser, and how it possibly could!
Maybe it's bogus untested code that we're not suppose to be running at all,
and other browsers don't run it but for some reason edbrowse does.
I don't know I'm sort of grasphing.
As I say I'll probably just write this one off for now unless you all have some insight.

Karl Dahlke

```* [Edbrowse-dev] infinite loop
@ 2017-01-27 14:51 Karl Dahlke
0 siblings, 0 replies; 5+ messages in thread
From: Karl Dahlke @ 2017-01-27 14:51 UTC (permalink / raw)
To: Edbrowse-dev

I have isolated the piece that causes the infinite loop, though it is still 10K of dog vomit js.

Karl Dahlke

```* [Edbrowse-dev] infinite loop
@ 2014-02-20 15:01 Karl Dahlke
From: Karl Dahlke @ 2014-02-20 15:01 UTC (permalink / raw)
To: Edbrowse-dev

I will respond to some of your other questions in a bit, but first ...

the hog memory button, as it is today, with jspool = 8, though I don't
think pool size matters, I push it , get my numbers, get the error;
then I push it again and edbrowse falls into an infinite spinning loop inside
JS_CallFunctionName().
The load average jumps up to 1.
You have to ^| quit to break out.

Now, even stranger, in buffers .c,
at line 4346 is jSyncup().
Just before that put this line in.

printf("findField returns xx\n", 27);

It's just a print statement, that's all, but it fixes the infinite loop.

Even stranger, remove the argument 27 from the print statement,
it isn't being used anyways, and the infinite loop is back.
Probably the strangest repeatable thing I've seen in 30 years of programming.

Karl Dahlke

• ```* Re: [Edbrowse-dev] infinite loop
2014-02-20 15:01 Karl Dahlke
@ 2014-02-20 20:25 ` Adam Thompson
0 siblings, 0 replies; 5+ messages in thread
To: Karl Dahlke; +Cc: Edbrowse-dev

On Thu, Feb 20, 2014 at 10:01:02AM -0500, Karl Dahlke wrote:
> I will respond to some of your other questions in a bit, but first ...
>
> the hog memory button, as it is today, with jspool = 8, though I don't
> think pool size matters, I push it , get my numbers, get the error;
> then I push it again and edbrowse falls into an infinite spinning loop inside
> JS_CallFunctionName().
> The load average jumps up to 1.
> You have to ^| quit to break out.
>
> Now, even stranger, in buffers .c,
> at line 4346 is jSyncup().
> Just before that put this line in.
>
> printf("findField returns xx\n", 27);
>
> It's just a print statement, that's all, but it fixes the infinite loop.
>
> Even stranger, remove the argument 27 from the print statement,
> it isn't being used anyways, and the infinite loop is back.
> Probably the strangest repeatable thing I've seen in 30 years of programming.

Yeah, that's both weird and concerning.
I've got no idea why this would happen,
particularly as I don't seem to be able to repeat it.
Any idea what the infinite loop is supposed to be doing ?

```end of thread, other threads:[~2019-09-10  8:13 UTC | newest]

```This is a public inbox, see mirroring instructions