[XFS] silence gcc4 warnings. the directory ones are wrong because of

information gcc could not find out (that a directory always has a ..
entry), the others are outright gcc bugs.

SGI-PV: 943511
SGI-Modid: xfs-linux:xfs-kern:200055a

Signed-off-by: Christoph Hellwig <hch@sgi.com>
Signed-off-by: Nathan Scott <nathans@sgi.com>
This commit is contained in:
Christoph Hellwig
2005-11-02 15:06:18 +11:00
committed by Nathan Scott
parent 9dac13e7ff
commit 5bde1ba99c
5 changed files with 20 additions and 4 deletions

View File

@@ -550,6 +550,13 @@ xfs_inobt_insrec(
int ptr; /* index in btree block for this rec */
xfs_inobt_rec_t *rp=NULL; /* pointer to btree records */
/*
* GCC doesn't understand the (arguably complex) control flow in
* this function and complains about uninitialized structure fields
* without this.
*/
memset(&nrec, 0, sizeof(nrec));
/*
* If we made it to the root level, allocate a new root block
* and we're done.