X-Git-Url: https://git.draconx.ca/gitweb/cdecl99.git/blobdiff_plain/1402a14592dde378698373044afbcef9c38ec2c2..1943156e7ba5c0318a54369a52297f74bad7b5b9:/src/parse.y diff --git a/src/parse.y b/src/parse.y index 80801c3..87d3f45 100644 --- a/src/parse.y +++ b/src/parse.y @@ -107,13 +107,7 @@ * name strings can be used directly in error messages and there is no * need for any string processing. */ -#define yytnamerr(a, b) ( (a) ? yytnamerr_copy(a, b) \ - : strlen(b) ) - -static size_t yytnamerr_copy(char *dst, const char *src) -{ - return cdecl__strlcpy(dst, src, strlen(src)+1); -} +#define yytnamerr(a, b) ( (a) ? cdecl__strlcpy(a, b, -1) : strlen(b) ) %} %code requires {