This is the mail archive of the gcc-bugs@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]

#pragma pack problem


hi

in the attached program i use #pragma pack(1) . I compile the program
with gcc version 2.95.2
and linked using gnu linker 2.9.1 and ran it gives the Bus Error (core
dumped) as it was trying to access the integer variable with
odd_address.
whereas if i compile the same program with
cc: Workshop Compilers 4.2  with -misalign option  (cc -misalign stru.c
) with solaris linker it doesn;t dump core

Is there any option like -misalign for the gnu linker to make the linker
accept the odd address
access.


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