Skip to content

Commit

Permalink
Fix uninitialized varible in zfs_do_userspace()
Browse files Browse the repository at this point in the history
When compiling under Debian Lenny with gcc version 4.3.2
(Debian 4.3.2-1.1) the following warning occurs.  To quiet
the warning initialize 'error' to zero.  Newer versions of
gcc correctly determine that this uninitialized varible is
impossible because ZFS_NUM_USERQUOTA_PROPS is known to be
greater than zero.

  cmd/zfs/zfs_main.c:2377: warning: "error" may be
  used uninitialized in this function

Signed-off-by: Brian Behlendorf <[email protected]>
  • Loading branch information
behlendorf committed Sep 27, 2011
1 parent dee28b0 commit c70602f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cmd/zfs/zfs_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -2374,7 +2374,7 @@ zfs_do_userspace(int argc, char **argv)
boolean_t prtnum = B_FALSE;
boolean_t parseable = B_FALSE;
boolean_t sid2posix = B_FALSE;
int error;
int error = 0;
int c;
zfs_sort_column_t *default_sortcol = NULL;
zfs_sort_column_t *sortcol = NULL;
Expand Down

0 comments on commit c70602f

Please sign in to comment.