Re: Bug in read_bitmap?

new topic     » goto parent     » topic index » view thread      » older message » newer message

At 05:58 PM 6/17/98 +0200, Jesus wrote:

>I'm trying to read a lot of bitmaps from disk with "read_bitmap".
>After reading ten (10) of them, I get an error telling I've open too many
>files.
>Does anybody know if read_bitmap does close the bitmap after reading it?.


Yes, read bitmap closes the file after
reading it, however it appears it dosn't
close the file after NOT reading it
(i.e. when returning an unsupported
format error).

The fix is simple; insert "close(fn)"
before each of the

"return BMP_UNSUPPORTED_FORMAT"

lines in the read_bitmap() function,
in image.e

I wonder how this one slipped through after
so long?


Graeme.

----------------------------------------------------

new topic     » goto parent     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu