Re: [PATCH V2] xfsprogs: check for size parsing errors in xfs_quota

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 01/27/12 13:26, Eric Sandeen wrote:
Doing something like

# xfs_quota -x -c 'limit -u bhard=1.2g ...

will cause cvtnum to fail and return a value of -1LL (because it
cannot parse the decimal), but the quota caller doesn't check
for this error value, casts it to U64, shifts right, and we end
up with an answer of 16 petabytes rather than erroring out.
Fix this.

Reported-by: James Lawrie<james@xxxxxxxxxxxxxx>
Signed-off-by: Eric Sandeen<sandeen@xxxxxxxxxx>
---

Looks and works great.

Reviewed-by: Mark Tinguely <tinguely@xxxxxxx>

_______________________________________________
xfs mailing list
xfs@xxxxxxxxxxx
http://oss.sgi.com/mailman/listinfo/xfs


[Index of Archives]     [Linux XFS Devel]     [Linux Filesystem Development]     [Filesystem Testing]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux