From: Domen Puncer Date: Thu, 23 Jun 2005 07:08:47 +0000 (-0700) Subject: [PATCH] ptrace_h8300: condition bugfix X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=15d20bfd606c4b4454aeaa05fc86f77994e48c92;p=GitHub%2FLineageOS%2Fandroid_kernel_samsung_universal7580.git [PATCH] ptrace_h8300: condition bugfix Assignment doesn't make much sense here as condition would always be true. Signed-off-by: Domen Puncer Signed-off-by: Yoshinori Sato Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/arch/h8300/platform/h8300h/ptrace_h8300h.c b/arch/h8300/platform/h8300h/ptrace_h8300h.c index 18e51a7167d..6ac93c05a1a 100644 --- a/arch/h8300/platform/h8300h/ptrace_h8300h.c +++ b/arch/h8300/platform/h8300h/ptrace_h8300h.c @@ -245,12 +245,12 @@ static unsigned short *getnextpc(struct task_struct *child, unsigned short *pc) addr = h8300_get_reg(child, regno-1+PT_ER1); return (unsigned short *)addr; case relb: - if ((inst = 0x55) || isbranch(child,inst & 0x0f)) + if (inst == 0x55 || isbranch(child,inst & 0x0f)) pc = (unsigned short *)((unsigned long)pc + ((signed char)(*fetch_p))); return pc+1; /* skip myself */ case relw: - if ((inst = 0x5c) || isbranch(child,(*fetch_p & 0xf0) >> 4)) + if (inst == 0x5c || isbranch(child,(*fetch_p & 0xf0) >> 4)) pc = (unsigned short *)((unsigned long)pc + ((signed short)(*(pc+1)))); return pc+2; /* skip myself */