(root)/
strace-6.5/
tests-m32/
ftruncate64.c
       1  /*
       2   * Copyright (c) 2015-2018 Dmitry V. Levin <ldv@strace.io>
       3   * Copyright (c) 2015-2021 The strace developers.
       4   * All rights reserved.
       5   *
       6   * SPDX-License-Identifier: GPL-2.0-or-later
       7   */
       8  
       9  #include "tests.h"
      10  #include "scno.h"
      11  
      12  #ifdef __NR_ftruncate64
      13  
      14  # include <stdio.h>
      15  # include <unistd.h>
      16  
      17  int
      18  main(void)
      19  {
      20  	const off_t len = 0xdefaceddeadbeefULL;
      21  
      22  	int rc = ftruncate(-1, len);
      23  	printf("ftruncate64(-1, %llu) = %d %s (%m)\n",
      24  	       (unsigned long long) len, rc, errno2name());
      25  
      26  	puts("+++ exited with 0 +++");
      27  	return 0;
      28  }
      29  
      30  #else
      31  
      32  SKIP_MAIN_UNDEFINED("__NR_ftruncate64")
      33  
      34  #endif