]> git.ipfire.org Git - thirdparty/rsync.git/commit
Fix warning about conflicting lseek/lseek64 prototypes
authorHolger Hoffstätte <holger@applied-asynchrony.com>
Mon, 4 Sep 2023 12:07:14 +0000 (14:07 +0200)
committerWayne Davison <wayne@opencoder.net>
Wed, 20 Nov 2024 05:28:39 +0000 (21:28 -0800)
commit07069880a21bd43dbc3b240e87ba6699c8725baa
tree5251318f45f3d359aa231e4d37fff95a70fafb35
parente55b190f4a7c0f9d942bc50be00ab176e3c4dc90
Fix warning about conflicting lseek/lseek64 prototypes

Clang rightfully complains about conflicting prototypes, as both lseek() variants
are redefined:

  syscall.c:394:10: warning: a function declaration without a prototype is deprecated
  in all versions of C and is treated as a zero-parameter prototype in C2x, conflicting
  with a previous declaration [-Wdeprecated-non-prototype]
        off64_t lseek64();
                ^
/usr/include/unistd.h:350:18: note: conflicting prototype is here
extern __off64_t lseek64 (int __fd, __off64_t __offset, int __whence)
                 ^
1 warning generated.

The point of the #ifdef is to build for the configured OFF_T; there is
no reason to redefine lseek/lseek64, which should have been found
via configure.

Signed-off-by: Holger Hoffstätte <holger@applied-asynchrony.com>
syscall.c