This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[committed] Fix libobjc/23108, reading and writing of structs is wrong


The problem here is that we don't get the correct size because we added the
rounded version of the size to the current size. The extra add is the problem.
Corrected it by removing the add.


Committed to the mainline after a build and test on powerpc-darwin and
x86_64-pc-linux-gnu.

Thanks,
Andrew Pinski

libobjc/ChangeLog:
	* archive.c (objc_write_type): Correct the element offset.
	(objc_read_type): Likewise.

gcc/testsuite/ChangeLog:
	* objc.dg/type-stream-1.m: New test.


Attachment: t.diff.txt
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]