LibFile complains about lack of memory

Timothy Baldwin T.E.Baldwin99 at members.leeds.ac.uk
Sun Aug 11 13:13:48 PDT 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Thursday 08 Aug 2002 10:50 pm, Alex Waugh wrote:
> In message <200208080054.26117.T.E.Baldwin99 at members.leeds.ac.uk>
>
>           Timothy Baldwin <T.E.Baldwin99 at members.leeds.ac.uk> wrote:
> > When atempting to create an empty library which already exists LibFile
> > complains about lack of memory, then exits successfully!
> >

[snipped errors]

> It will also give the same error if you try to add a zero length file to
> an library. I suspect it is either misreporting the error, or failing to
> take account of boundary cases correctly. I might have a go at fixing it
> at some point.
>
> Alex

Heres a patch for exiting correctly on errors:

diff -burN gccsdk-old/riscos-aof/libfile/LibFile.cc 
gccsdk2/riscos-aof/libfile/LibFile.cc
- --- gccsdk-old/riscos-aof/libfile/LibFile.cc	Sat Aug 10 18:01:47 2002
+++ gccsdk2/riscos-aof/libfile/LibFile.cc	Thu Aug  8 14:20:15 2002
@@ -13,6 +13,7 @@
   catch (BError err)
     {
       cerr << &err;
+      return 1;
     }

   return 0;

- -- 
Timothy Baldwin
Member WYLUG, SWP, ANL, Leeds SA, Leeds Anti-war coalition
Stop the EU Copyright Directive!

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE9VsV9RyxeA0fSpFERAjA5AJ9MPKXb/oYlpMqDevBE+iQvMfnctQCeOIa6
MXN3j+WQJI9xIezkefyUw+g=
=4bx5
-----END PGP SIGNATURE-----



More information about the gcc mailing list