From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on dcvr.yhbt.net X-Spam-Level: X-Spam-ASN: AS6461 209.249.0.0/16 X-Spam-Status: No, score=-2.4 required=3.0 tests=AWL,BAYES_00,RCVD_IN_XBL, SPF_FAIL,SPF_HELO_FAIL shortcircuit=no autolearn=no version=3.3.2 Received: from 80x24.org (exit.kapustik.info [209.249.157.69]) by dcvr.yhbt.net (Postfix) with ESMTP id AFDAF633807 for ; Sun, 1 May 2016 22:18:38 +0000 (UTC) From: Eric Wong To: meta@public-inbox.org Subject: [PATCH] git-http-backend: use real lseek for Content-Range Date: Sun, 1 May 2016 22:18:35 +0000 Message-Id: <20160501221835.25414-1-e@80x24.org> List-Id: Since we use sysread, we must use sysseek for symmetry although PerlIO may be doing a real lseek with "seek", anyways. Fixes: 310819ea86ac ("git-http-backend: favor sysread for regular files") --- lib/PublicInbox/GitHTTPBackend.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/PublicInbox/GitHTTPBackend.pm b/lib/PublicInbox/GitHTTPBackend.pm index 5863462..5169e97 100644 --- a/lib/PublicInbox/GitHTTPBackend.pm +++ b/lib/PublicInbox/GitHTTPBackend.pm @@ -178,7 +178,7 @@ sub prepare_range { if ($len <= 0) { $code = 416; } else { - seek($in, $beg, SEEK_SET) or return [ 500, [], [] ]; + sysseek($in, $beg, SEEK_SET) or return [ 500, [], [] ]; push @$h, qw(Accept-Ranges bytes Content-Range); push @$h, "bytes $beg-$end/$size"; -- EW