From f3fa698cfd6d947a1f18d278af1663a7c7ec7053 Mon Sep 17 00:00:00 2001 From: Benno Schulenberg Date: Thu, 18 Sep 2025 10:57:05 +0200 Subject: [PATCH] fallocate: redo four tweaks that were accidentally undone Recent commit c407a13fc1 undid some changes that were made by commits 762f295a02 and 325a269995. Redo these changes. Signed-off-by: Benno Schulenberg --- sys-utils/fallocate.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/sys-utils/fallocate.c b/sys-utils/fallocate.c index 30c391406..afd615537 100644 --- a/sys-utils/fallocate.c +++ b/sys-utils/fallocate.c @@ -17,9 +17,8 @@ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * - * You should have received a copy of the GNU General Public License along - * with this program; if not, write to the Free Software Foundation, Inc., - * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . */ #include #include @@ -396,16 +395,16 @@ int main(int argc, char **argv) if (length == -2LL) length = 0; if (length < 0) - errx(EXIT_FAILURE, _("invalid length value specified")); + errx(EXIT_FAILURE, _("invalid length")); } else { /* it's safer to require the range specification (--length --offset) */ if (length == -2LL) errx(EXIT_FAILURE, _("no length argument specified")); if (length <= 0) - errx(EXIT_FAILURE, _("invalid length value specified")); + errx(EXIT_FAILURE, _("invalid length")); } if (offset < 0) - errx(EXIT_FAILURE, _("invalid offset value specified")); + errx(EXIT_FAILURE, _("invalid offset")); /* O_CREAT makes sense only for the default fallocate(2) behavior * when mode is no specified and new space is allocated */ -- 2.47.3