4
0
mirror of git://sourceware.org/git/newlib-cygwin.git synced 2025-01-19 12:59:21 +08:00
newlib-cygwin/libgloss/riscv/semihost-sys_fstat.c
2020-12-16 16:40:34 -05:00

20 lines
457 B
C

/*
* Copyright (C) 2020 Embecosm Limited
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <string.h>
#include <sys/stat.h>
#include "semihost_stat.h"
/* Status of an open file. The sys/stat.h header file required is
distributed in the include subdirectory for this C library. */
int
_fstat (int file, struct stat *st)
{
/* Initialize st as not all fields will be set. */
memset (st, 0, sizeof (*st));
return __stat_common (file, st);
}