···244244 result = iget_locked(dir->i_sb, ino);245245 if (!result) {246246 hpfs_error(dir->i_sb, "hpfs_lookup: can't get inode");247247+ result = ERR_PTR(-ENOMEM);247248 goto bail1;248249 }249250 if (result->i_state & I_NEW) {···267266268267 if (de->has_acl || de->has_xtd_perm) if (!sb_rdonly(dir->i_sb)) {269268 hpfs_error(result->i_sb, "ACLs or XPERM found. This is probably HPFS386. This driver doesn't support it now. Send me some info on these structures");269269+ iput(result);270270+ result = ERR_PTR(-EINVAL);270271 goto bail1;271272 }272273···304301 }305302 }306303304304+bail1:307305 hpfs_brelse4(&qbh);308306309307 /*310308 * Made it.311309 */312310313313- end:314314- end_add:311311+end:312312+end_add:315313 hpfs_unlock(dir->i_sb);316316- d_add(dentry, result);317317- return NULL;318318-319319- /*320320- * Didn't.321321- */322322- bail1:323323-324324- hpfs_brelse4(&qbh);325325-326326- /*bail:*/327327-328328- hpfs_unlock(dir->i_sb);329329- return ERR_PTR(-ENOENT);314314+ return d_splice_alias(result, dentry);330315}331316332317const struct file_operations hpfs_dir_ops =