Commit 2f5930c1 authored by Al Viro's avatar Al Viro Committed by Steve French
Browse files

ksmbd: don't open-code file_path()

parent 4fe89d07
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -5413,7 +5413,7 @@ static int smb2_rename(struct ksmbd_work *work,
	if (!pathname)
		return -ENOMEM;

	abs_oldname = d_path(&fp->filp->f_path, pathname, PATH_MAX);
	abs_oldname = file_path(fp->filp, pathname, PATH_MAX);
	if (IS_ERR(abs_oldname)) {
		rc = -EINVAL;
		goto out;
@@ -5548,7 +5548,7 @@ static int smb2_create_link(struct ksmbd_work *work,
	}

	ksmbd_debug(SMB, "link name is %s\n", link_name);
	target_name = d_path(&filp->f_path, pathname, PATH_MAX);
	target_name = file_path(filp, pathname, PATH_MAX);
	if (IS_ERR(target_name)) {
		rc = -EINVAL;
		goto out;