Merge tag 'ext4_for_linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tytso...
[sfrench/cifs-2.6.git] / fs / ext4 / ioctl.c
index 7497f50cb29336add4aa7ef17ddf5176193493d1..28cc412852afba41650ffeee2e713e2345b60511 100644 (file)
@@ -365,7 +365,7 @@ static int ext4_ioctl_setproject(struct file *filp, __u32 projid)
                struct dquot *transfer_to[MAXQUOTAS] = { };
 
                transfer_to[PRJQUOTA] = dqget(sb, make_kqid_projid(kprojid));
-               if (transfer_to[PRJQUOTA]) {
+               if (!IS_ERR(transfer_to[PRJQUOTA])) {
                        err = __dquot_transfer(inode, transfer_to);
                        dqput(transfer_to[PRJQUOTA]);
                        if (err)