Skip to content

Commit

Permalink
[PATCH] ptrace_h8300: condition bugfix
Browse files Browse the repository at this point in the history
Assignment doesn't make much sense here as condition would always be true.

Signed-off-by: Domen Puncer <domen@coderock.org>
Signed-off-by: Yoshinori Sato <ysato@users.sourceforge.jp>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
  • Loading branch information
Domen Puncer authored and Linus Torvalds committed Jun 23, 2005
1 parent 76381fe commit 15d20bf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions arch/h8300/platform/h8300h/ptrace_h8300h.c
Original file line number Diff line number Diff line change
Expand Up @@ -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 */
Expand Down

0 comments on commit 15d20bf

Please sign in to comment.