diff --git a/vvp/vpip_bin.cc b/vvp/vpip_bin.cc index 0deff0327..ecbcd9eb6 100644 --- a/vvp/vpip_bin.cc +++ b/vvp/vpip_bin.cc @@ -35,7 +35,7 @@ void vpip_bin_str_to_vec4(vvp_vector4_t&vec4, const char*buf) unsigned skip_chars = 0; const char*tbuf = buf; /* Find the number of non-numeric characters. */ - while (tbuf = strpbrk(tbuf, "-_")) { + while ((tbuf = strpbrk(tbuf, "-_"))) { skip_chars += 1; tbuf += 1; } diff --git a/vvp/vpip_hex.cc b/vvp/vpip_hex.cc index cd7004ebd..3846ac235 100644 --- a/vvp/vpip_hex.cc +++ b/vvp/vpip_hex.cc @@ -36,7 +36,7 @@ void vpip_hex_str_to_vec4(vvp_vector4_t&val, const char*str) unsigned skip_chars = 0; const char*tstr = str; /* Find the number of non-numeric characters. */ - while (tstr = strpbrk(tstr, "-_")) { + while ((tstr = strpbrk(tstr, "-_"))) { skip_chars += 1; tstr += 1; } diff --git a/vvp/vpip_oct.cc b/vvp/vpip_oct.cc index 90efed18a..0b28e102e 100644 --- a/vvp/vpip_oct.cc +++ b/vvp/vpip_oct.cc @@ -36,7 +36,7 @@ void vpip_oct_str_to_vec4(vvp_vector4_t&val, const char*str) unsigned skip_chars = 0; const char*tstr = str; /* Find the number of non-numeric characters. */ - while (tstr = strpbrk(tstr, "-_")) { + while ((tstr = strpbrk(tstr, "-_"))) { skip_chars += 1; tstr += 1; }