Blame io/tst-copy_file_range-compat.c

Packit Service 1c5418
/* Test the fallback implementation of copy_file_range.
Packit Service 1c5418
   Copyright (C) 2017-2018 Free Software Foundation, Inc.
Packit Service 1c5418
   This file is part of the GNU C Library.
Packit Service 1c5418
Packit Service 1c5418
   The GNU C Library is free software; you can redistribute it and/or
Packit Service 1c5418
   modify it under the terms of the GNU Lesser General Public
Packit Service 1c5418
   License as published by the Free Software Foundation; either
Packit Service 1c5418
   version 2.1 of the License, or (at your option) any later version.
Packit Service 1c5418
Packit Service 1c5418
   The GNU C Library is distributed in the hope that it will be useful,
Packit Service 1c5418
   but WITHOUT ANY WARRANTY; without even the implied warranty of
Packit Service 1c5418
   MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
Packit Service 1c5418
   Lesser General Public License for more details.
Packit Service 1c5418
Packit Service 1c5418
   You should have received a copy of the GNU Lesser General Public
Packit Service 1c5418
   License along with the GNU C Library; if not, see
Packit Service 1c5418
   <http://www.gnu.org/licenses/>.  */
Packit Service 1c5418
Packit Service 1c5418
/* Get the declaration of the official copy_of_range function.  */
Packit Service 1c5418
#include <unistd.h>
Packit Service 1c5418
Packit Service 1c5418
/* Compile a local version of copy_file_range.  */
Packit Service 1c5418
#define COPY_FILE_RANGE_DECL static
Packit Service 1c5418
#define COPY_FILE_RANGE copy_file_range_compat
Packit Service 1c5418
#include <io/copy_file_range-compat.c>
Packit Service 1c5418
Packit Service 1c5418
/* Re-use the test, but run it against copy_file_range_compat defined
Packit Service 1c5418
   above.  */
Packit Service 1c5418
#define copy_file_range copy_file_range_compat
Packit Service 1c5418
#include "tst-copy_file_range.c"