Re: Pixbuf loading question
- From: nico <nbd free fr>
- To: gtk-list gnome org
- Subject: Re: Pixbuf loading question
- Date: Mon, 07 Apr 2008 16:23:32 +0200
Paul Davis a écrit :
>
> assuming you've got more stuff on disk than you have memory, that should
> work, most of the time.
>
Ok
>
>>> another is a small
>>> program that allocates more and more memory until it fails.
>>>
>>>
>> Do you have an example for that ? Like always creating a big object in
>> a for ever loop ?
>>
>
> pretty much. something like:
>
> #include <stdlib.h>
>
> int
> main ()
> {
> size_t sz = 10 * 1024 * 1024;
>
> while (1) {
> if (malloc (sz) == 0) {
> break;
> }
> }
> return 0;
> }
>
>
> should do it. depending on how much memory you have, it can take a while
> (several seconds).
>
>
Thanks very much. I try it right now.
Nico
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]