summaryrefslogtreecommitdiffstats
path: root/sys/compat/linux/linux_getcwd.c
diff options
context:
space:
mode:
Diffstat (limited to 'sys/compat/linux/linux_getcwd.c')
-rw-r--r--sys/compat/linux/linux_getcwd.c14
1 files changed, 4 insertions, 10 deletions
diff --git a/sys/compat/linux/linux_getcwd.c b/sys/compat/linux/linux_getcwd.c
index 1e2dabae..2835d5c 100644
--- a/sys/compat/linux/linux_getcwd.c
+++ b/sys/compat/linux/linux_getcwd.c
@@ -327,11 +327,8 @@ linux_getcwd_common (lvp, rvp, bpp, bufp, limit, flags, td)
*/
error = vn_lock(lvp, LK_EXCLUSIVE | LK_RETRY, td);
- if (error) {
- vrele(lvp);
- lvp = NULL;
- goto out;
- }
+ if (error != 0)
+ panic("vn_lock LK_RETRY returned error %d", error);
if (bufp)
bp = *bpp;
/*
@@ -383,11 +380,8 @@ linux_getcwd_common (lvp, rvp, bpp, bufp, limit, flags, td)
}
VREF(lvp);
error = vn_lock(lvp, LK_EXCLUSIVE | LK_RETRY, td);
- if (error != 0) {
- vrele(lvp);
- lvp = NULL;
- goto out;
- }
+ if (error != 0)
+ panic("vn_lock LK_RETRY returned %d", error);
}
error = linux_getcwd_scandir(&lvp, &uvp, &bp, bufp, td);
if (error)
OpenPOWER on IntegriCloud