mirror of
https://git.savannah.gnu.org/git/bison.git
synced 2026-03-15 15:23:02 +00:00
Fix `%nonassoc and eof'.
* src/state.c (errs_dup): Aaaah! The failure was due to bytes which were not properly copied! Replace memcpy (res->errs, src->errs, src->nerrs); with memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0])); !!! * tests/regression.at (%nonassoc and eof): Adjust to newest Autotest: `.' is not in the PATH.
This commit is contained in:
@@ -61,7 +61,7 @@ errs *
|
||||
errs_dup (errs *src)
|
||||
{
|
||||
errs *res = errs_new (src->nerrs);
|
||||
memcpy (res->errs, src->errs, src->nerrs);
|
||||
memcpy (res->errs, src->errs, src->nerrs * sizeof (src->errs[0]));
|
||||
return res;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user