diff --git a/gdb/ChangeLog b/gdb/ChangeLog index c4a98be285..dfee35abde 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2011-04-19 Pierre Muller + + * xcoffread.c (process_xcoff_symbol): ARI fix: Avoid assignment + inside if clause. + 2011-04-19 Pierre Muller Pedro Alves diff --git a/gdb/xcoffread.c b/gdb/xcoffread.c index fd60447210..4dd048d5d9 100644 --- a/gdb/xcoffread.c +++ b/gdb/xcoffread.c @@ -1585,7 +1585,11 @@ process_xcoff_symbol (struct coff_symbol *cs, struct objfile *objfile) where we need to, which is not necessarily super-clean, but seems workable enough. */ - if (*name == ':' || (pp = (char *) strchr (name, ':')) == NULL) + if (*name == ':') + return NULL; + + pp = (char *) strchr (name, ':'); + if (pp == NULL) return NULL; ++pp;