Use the size of struct fpreg rather than of the pointer to it when copying
the FPU state. Reviewed by: marcel Approved by: re (kib) MFC after: 1 week
This commit is contained in:
parent
e31fe879a8
commit
21a305d4af
@ -92,18 +92,21 @@ pt_ucontext_to_reg(const ucontext_t *uc, struct reg *r)
|
||||
void
|
||||
pt_fpreg_to_ucontext(const struct fpreg* r, ucontext_t *uc)
|
||||
{
|
||||
memcpy(&uc->uc_mcontext.mc_fpstate, r, sizeof(r));
|
||||
|
||||
memcpy(&uc->uc_mcontext.mc_fpstate, r, sizeof(*r));
|
||||
}
|
||||
|
||||
void
|
||||
pt_ucontext_to_fpreg(const ucontext_t *uc, struct fpreg *r)
|
||||
{
|
||||
memcpy(r, &uc->uc_mcontext.mc_fpstate, sizeof(r));
|
||||
|
||||
memcpy(r, &uc->uc_mcontext.mc_fpstate, sizeof(*r));
|
||||
}
|
||||
|
||||
void
|
||||
pt_md_init(void)
|
||||
{
|
||||
|
||||
/* Nothing to do */
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user