Commit 9c169915 authored by Poyo VL's avatar Poyo VL Committed by Alex Elder

xfs: eliminate some newly-reported gcc warnings

Ionut Gabriel Popescu <poyo_vl@yahoo.com> submitted a simple change
to eliminate some "may be used uninitialized" warnings when building
XFS.  The reported condition seems to be something that GCC did not
used to recognize or report.  The warnings were produced by:

    gcc version 4.5.0 20100604
    [gcc-4_5-branch revision 160292] (SUSE Linux)
Signed-off-by: default avatarIonut Gabriel Popescu <poyo_vl@yahoo.com>
Signed-off-by: default avatarAlex Elder <aelder@sgi.com>
parent c0e59e1a
...@@ -675,7 +675,7 @@ xfs_alloc_ag_vextent_near( ...@@ -675,7 +675,7 @@ xfs_alloc_ag_vextent_near(
xfs_agblock_t gtbnoa; /* aligned ... */ xfs_agblock_t gtbnoa; /* aligned ... */
xfs_extlen_t gtdiff; /* difference to right side entry */ xfs_extlen_t gtdiff; /* difference to right side entry */
xfs_extlen_t gtlen; /* length of right side entry */ xfs_extlen_t gtlen; /* length of right side entry */
xfs_extlen_t gtlena; /* aligned ... */ xfs_extlen_t gtlena = 0; /* aligned ... */
xfs_agblock_t gtnew; /* useful start bno of right side */ xfs_agblock_t gtnew; /* useful start bno of right side */
int error; /* error code */ int error; /* error code */
int i; /* result code, temporary */ int i; /* result code, temporary */
...@@ -684,7 +684,7 @@ xfs_alloc_ag_vextent_near( ...@@ -684,7 +684,7 @@ xfs_alloc_ag_vextent_near(
xfs_agblock_t ltbnoa; /* aligned ... */ xfs_agblock_t ltbnoa; /* aligned ... */
xfs_extlen_t ltdiff; /* difference to left side entry */ xfs_extlen_t ltdiff; /* difference to left side entry */
xfs_extlen_t ltlen; /* length of left side entry */ xfs_extlen_t ltlen; /* length of left side entry */
xfs_extlen_t ltlena; /* aligned ... */ xfs_extlen_t ltlena = 0; /* aligned ... */
xfs_agblock_t ltnew; /* useful start bno of left side */ xfs_agblock_t ltnew; /* useful start bno of left side */
xfs_extlen_t rlen; /* length of returned extent */ xfs_extlen_t rlen; /* length of returned extent */
#if defined(DEBUG) && defined(__KERNEL__) #if defined(DEBUG) && defined(__KERNEL__)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment