Skip to content

Commit

Permalink
Fix zfs-0.8.3 'make lint' warnings
Browse files Browse the repository at this point in the history
Fix these lint warnings on zfs-0.8.3:

$ make lint
[module/spl/spl-vnode.c:494]: (error) Uninitialized variable: fp
[module/spl/spl-vnode.c:706]: (error) Uninitialized variable: fp
[module/spl/spl-vnode.c:706]: (error) Uninitialized variable: next_fp
^CMakefile:1632: recipe for target 'cppcheck' failed
make: *** [cppcheck] Interrupt

Signed-off-by: Tony Hutter <[email protected]>
  • Loading branch information
tonyhutter committed Jan 7, 2020
1 parent 4ad592c commit ad3dbdf
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions module/spl/spl-vnode.c
Original file line number Diff line number Diff line change
Expand Up @@ -489,7 +489,7 @@ EXPORT_SYMBOL(vn_space);
static file_t *
file_find(int fd, struct task_struct *task)
{
file_t *fp;
file_t *fp = NULL;

list_for_each_entry(fp, &vn_file_list, f_list) {
if (fd == fp->f_fd && fp->f_task == task) {
Expand Down Expand Up @@ -698,7 +698,7 @@ spl_vn_init(void)
void
spl_vn_fini(void)
{
file_t *fp, *next_fp;
file_t *fp = NULL, *next_fp = NULL;
int leaked = 0;

spin_lock(&vn_file_lock);
Expand Down

0 comments on commit ad3dbdf

Please sign in to comment.