lkml.org 
[lkml]   [1999]   [May]   [30]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRe: Bug? Allocation of too much memory hangs system, kernel 2.2.*
Date

> If you like you can send me your recursive proggy and I'll try to run it
> here.

Please try the following:

-------------------------------------
# include "stdio.h"

static int count = 0;
# define MAX (1024*1024)
void foo(){
char a[MAX];
int i;

printf ("%d\n", count++);

for (i = 0; i < MAX; i += 100) {
a[i] = i % 256;
}

foo();
}
int main(){
foo();
return 0;
}
-------------------------------------

after printing 375, the system stops as described in my problem report.

Jürgen



------------------------------------------------------------------------------
Dr. Juergen Vollmer, Viktoriastrasse 15, D-76133 Karlsruhe
office: vollmer@cocolab.de Tel: +49(721) 9204871 Fax: +49(721) 24874
private: Juergen.Vollmer@acm.org Tel: +49(721) 24874 Fax: +49(721) 24874
WWW: www.cocolab.de/vollmer
------------------------------------------------------------------------------


[unhandled content-type:application/pgp-signature]
\
 
 \ /
  Last update: 2005-03-22 13:52    [W:0.047 / U:0.056 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site