John Scipione 93e5d9fa15 DiskUsage: Fix CID 1288122
In hrev48870 I made some updates to DiskUsage which accidentally caused this
CID.

Both the volume and item pointers were going out of scope without being deleted
in the error case leading to a resource leak. This commit seeks to fix the
problem by creating these objects as late as possible after the error checking.

tempVolume, which, as it's name implies, is created temporarily on the stack is
used instead of volume up until the point that AddTab() requires a more
permanent heap-stored volume pointer. Same goes for the VolumeView and
VolumeTab. name is created temporarily on the stack as well which works
because it is copied when passed into VolumeView constructor by the grandparent
BHandler before going out of scope.
2015-03-13 16:28:47 -04:00
..
2015-03-13 16:28:47 -04:00
2015-01-06 15:23:28 +01:00