X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/f518dbaf46eb28bd39695474de6118683d905e5f..a17187e56386747a9b4d9633c3d116c2087f2b8b:/src/files.c?ds=sidebyside diff --git a/src/files.c b/src/files.c index ceb0489a..550e42ed 100644 --- a/src/files.c +++ b/src/files.c @@ -215,10 +215,9 @@ file_name_split (const char *file_name, if (*ext) { size_t baselen = *ext - *base; - size_t dottablen = 4; + size_t dottablen = sizeof (TAB_EXT) - 1; if (dottablen < baselen - && (strncmp (*ext - dottablen, ".tab", dottablen) == 0 - || strncmp (*ext - dottablen, "_tab", dottablen) == 0)) + && STRPREFIX_LIT (TAB_EXT, *ext - dottablen)) *tab = *ext - dottablen; } }