Memory leaks revisited

Stefano Corsi <[email protected]> Fri, 2 May 2003 15:13:44 +0000
Newsgroups gmane.comp.lang.moto.devel
Organization Moto Project
Message-ID <[email protected]>
I'm still experimenting with odd, iterative tests:

void test3(int count) {
    for (int a =3D 0; a < 100; a++) {
        for (int i =3D 0; i < seed; i++) {
            String arr[][][][][][][] =3D <String[][][][][][][]>{{{{{{{ "d=
og"=20
}}}}}}};
            print arr[0][0][0][0][0][0][0] + "\n";
        }
    }
}

test3(1000);

This one fails with both moto_0_19_1 and my moto_opo branch:

### Allocation failure!
Uncaught AllocationFailureException
   message:

AllocationFailureException thrown in test3(excpfn.c:47)
   called from function <main>(prova.moto:12)

The strange thing is that it fails also in compiled mode:=20

### Allocation failure!
### Allocation failure!
Segmentation fault

It succeds, on the other side, with count =3D 100 and prints "dog" 10.000=
=20
times...

test3(100);

Stefano