aboutsummaryrefslogtreecommitdiff
path: root/libbb/get_volsize.c
diff options
context:
space:
mode:
Diffstat (limited to 'libbb/get_volsize.c')
-rw-r--r--libbb/get_volsize.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libbb/get_volsize.c b/libbb/get_volsize.c
index 241ceda9b..087efb3c7 100644
--- a/libbb/get_volsize.c
+++ b/libbb/get_volsize.c
@@ -18,7 +18,7 @@ uoff_t FAST_FUNC get_volume_size_in_bytes(int fd,
18 if (override) { 18 if (override) {
19 result = XATOOFF(override); 19 result = XATOOFF(override);
20 if (result >= (uoff_t)(MAXINT(off_t)) / override_units) 20 if (result >= (uoff_t)(MAXINT(off_t)) / override_units)
21 bb_error_msg_and_die("image size is too big"); 21 bb_simple_error_msg_and_die("image size is too big");
22 result *= override_units; 22 result *= override_units;
23 /* seek past end fails on block devices but works on files */ 23 /* seek past end fails on block devices but works on files */
24 if (lseek(fd, result - 1, SEEK_SET) != (off_t)-1) { 24 if (lseek(fd, result - 1, SEEK_SET) != (off_t)-1) {
@@ -42,7 +42,7 @@ uoff_t FAST_FUNC get_volume_size_in_bytes(int fd,
42 * 42 *
43 * Picked 16k arbitrarily: */ 43 * Picked 16k arbitrarily: */
44 if (result < 16*1024) 44 if (result < 16*1024)
45 bb_error_msg_and_die("image is too small"); 45 bb_simple_error_msg_and_die("image is too small");
46 46
47 return result; 47 return result;
48} 48}