mirror of
https://git.savannah.gnu.org/git/tar.git
synced 2026-09-07 08:46:57 +00:00
Include bounds in forward declaration for xhdr_tab.
This commit is contained in:
+7
-1
@@ -36,7 +36,10 @@ struct xhdr_tab
|
||||
void (*decoder) (struct tar_stat_info *, char const *);
|
||||
};
|
||||
|
||||
static struct xhdr_tab const xhdr_tab[];
|
||||
/* This declaration must specify the number of elements in xhdr_tab,
|
||||
because ISO C99 section 6.9.2 prohibits a tentative definition that
|
||||
has both internal linkage and incomplete type. */
|
||||
static struct xhdr_tab const xhdr_tab[13];
|
||||
|
||||
static struct xhdr_tab const *
|
||||
locate_handler (char const *keyword)
|
||||
@@ -420,6 +423,9 @@ static struct xhdr_tab const xhdr_tab[] = {
|
||||
{ "uid", uid_coder, uid_decoder },
|
||||
{ "uname", uname_coder, uname_decoder },
|
||||
|
||||
/* The number of entries in xhdr_tab must agree with the array
|
||||
bounds in xhdr_tab's forward declaration. */
|
||||
|
||||
#if 0 /* GNU private keywords (not yet implemented) */
|
||||
/* Sparse file handling */
|
||||
{ "GNU.sparse.offset", sparse_offset_coder, sparse_offset_decoder },
|
||||
|
||||
Reference in New Issue
Block a user