Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » Error in Gccbuilder
Error in Gccbuilder [message #7588] Mon, 08 January 2007 17:55 Go to previous message
MikeP is currently offline  MikeP
Messages: 4
Registered: January 2007
Junior Member
In gccbuilder.cpp is missing compression routines on non-array Binary objects.

here is the correct part:
		else {
			BinObjInfo::Block& b = belem[0];
			fo << "char " << ident << "[] =\n";
			String data = ::LoadFile(b.file);
			if(data.IsVoid())
				throw Exc(NFormat("Error reading file '%s'", b.file));
			if(data.GetLength() != b.length)
				throw Exc(NFormat("length of file '%s' changed (%d -> %d) during object creation",
					b.file, b.length, data.GetLength()));
			switch(b.encoding) {
				case BinObjInfo::Block::ENC_BZ2: data = BZ2Compress(data); break;
				case BinObjInfo::Block::ENC_ZIP: data = ZCompress(data); break;
			}
			fo << AsCString(data, 70) << ";\n\n"
			"int " << ident << "_length = " << data.GetLength() << ";\n\n";
		}

 
Read Message
Read Message
Read Message
Read Message
Previous Topic: brc sample problem
Next Topic: RegExp support
Goto Forum:
  


Current Time: Sun Apr 27 23:30:52 CEST 2025

Total time taken to generate the page: 0.02446 seconds