Silence 'old_umask' uninit variable warning

Recent changes have caused older versions of gcc to mistakenly
flag 'old_umask' in vn_open() as an unitialized variable.  To
silence the warning initialize it.

  kernel.c: In function 'vn_open':
  kernel.c:525:6: error: 'old_umask' may be used uninitialized
  in this function

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
This commit is contained in:
Brian Behlendorf 2013-04-29 14:07:46 -07:00
parent 937210a54b
commit a4914d38a7
1 changed files with 1 additions and 1 deletions

View File

@ -522,7 +522,7 @@ vn_open(char *path, int x1, int flags, int mode, vnode_t **vpp, int x2, int x3)
{
int fd;
vnode_t *vp;
int old_umask;
int old_umask = 0;
char *realpath;
struct stat64 st;
int err;