diff options
Diffstat (limited to 'fs/autofs/expire.c')
-rw-r--r-- | fs/autofs/expire.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/fs/autofs/expire.c b/fs/autofs/expire.c index d441244b79df..28d9c2b1b3bb 100644 --- a/fs/autofs/expire.c +++ b/fs/autofs/expire.c | |||
@@ -596,7 +596,6 @@ int autofs_expire_run(struct super_block *sb, | |||
596 | pkt.len = dentry->d_name.len; | 596 | pkt.len = dentry->d_name.len; |
597 | memcpy(pkt.name, dentry->d_name.name, pkt.len); | 597 | memcpy(pkt.name, dentry->d_name.name, pkt.len); |
598 | pkt.name[pkt.len] = '\0'; | 598 | pkt.name[pkt.len] = '\0'; |
599 | dput(dentry); | ||
600 | 599 | ||
601 | if (copy_to_user(pkt_p, &pkt, sizeof(struct autofs_packet_expire))) | 600 | if (copy_to_user(pkt_p, &pkt, sizeof(struct autofs_packet_expire))) |
602 | ret = -EFAULT; | 601 | ret = -EFAULT; |
@@ -609,6 +608,8 @@ int autofs_expire_run(struct super_block *sb, | |||
609 | complete_all(&ino->expire_complete); | 608 | complete_all(&ino->expire_complete); |
610 | spin_unlock(&sbi->fs_lock); | 609 | spin_unlock(&sbi->fs_lock); |
611 | 610 | ||
611 | dput(dentry); | ||
612 | |||
612 | return ret; | 613 | return ret; |
613 | } | 614 | } |
614 | 615 | ||