diff options
author | Richard Henderson <rth@redhat.com> | 2005-07-01 19:18:13 -0700 |
---|---|---|
committer | Richard Henderson <rth@gcc.gnu.org> | 2005-07-01 19:18:13 -0700 |
commit | 606c33f195f98232adedfef307b07cdadea2bfd8 (patch) | |
tree | 2bef19d83b4a204d0292913999366e0c44c9dcc2 /gcc | |
parent | 60d436c9b04d092ba05389b0cd92750678cc24cd (diff) | |
download | gcc-606c33f195f98232adedfef307b07cdadea2bfd8.zip gcc-606c33f195f98232adedfef307b07cdadea2bfd8.tar.gz gcc-606c33f195f98232adedfef307b07cdadea2bfd8.tar.bz2 |
linux-unwind.h (x86_64_fallback_frame_state): Cast to void * before struct sigcontext *.
* config/i386/linux-unwind.h (x86_64_fallback_frame_state): Cast to
void * before struct sigcontext *.
(x86_fallback_frame_state): Likewise.
From-SVN: r101529
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/ChangeLog | 6 | ||||
-rw-r--r-- | gcc/config/i386/linux-unwind.h | 10 |
2 files changed, 14 insertions, 2 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog index d07f64e..a29ff99 100644 --- a/gcc/ChangeLog +++ b/gcc/ChangeLog @@ -1,3 +1,9 @@ +2005-07-01 Richard Henderson <rth@redhat.com> + + * config/i386/linux-unwind.h (x86_64_fallback_frame_state): Cast to + void * before struct sigcontext *. + (x86_fallback_frame_state): Likewise. + 2005-07-01 James E. Wilson <wilson@specifixinc.com> * doc/invoke.texi (-funit-at-a-time): Correct grammar in second bullet. diff --git a/gcc/config/i386/linux-unwind.h b/gcc/config/i386/linux-unwind.h index 919c3a4..6ca1309 100644 --- a/gcc/config/i386/linux-unwind.h +++ b/gcc/config/i386/linux-unwind.h @@ -52,7 +52,10 @@ x86_64_fallback_frame_state (struct _Unwind_Context *context, && *(unsigned long *)(pc+1) == 0x050f0000000fc0c7) { struct ucontext *uc_ = context->cfa; - sc = (struct sigcontext *) &uc_->uc_mcontext; + /* The void * cast is necessary to avoid an aliasing warning. + The aliasing warning is correct, but should not be a problem + because it does not alias anything. */ + sc = (struct sigcontext *) (void *) &uc_->uc_mcontext; } else return _URC_END_OF_STACK; @@ -138,7 +141,10 @@ x86_fallback_frame_state (struct _Unwind_Context *context, struct siginfo info; struct ucontext uc; } *rt_ = context->cfa; - sc = (struct sigcontext *) &rt_->uc.uc_mcontext; + /* The void * cast is necessary to avoid an aliasing warning. + The aliasing warning is correct, but should not be a problem + because it does not alias anything. */ + sc = (struct sigcontext *) (void *) &rt_->uc.uc_mcontext; } else return _URC_END_OF_STACK; |