mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
lib/readdir.c: Include unistd.h for unlink(2)
On riscv64:
readdir.c: In function ‘guestfs_impl_readdir’:
readdir.c:127:3: error: implicit declaration of function ‘unlink’ [-Werror=implicit-function-declaration]
127 | unlink (tmpfn);
| ^~~~~~
I also changed the #include lines to make them look a bit more
like use in other files.
This commit is contained in:
@@ -16,12 +16,14 @@
|
||||
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
*/
|
||||
|
||||
#include <config.h> /* UNIX_PATH_MAX, needed by "guestfs-internal.h" */
|
||||
#include <config.h>
|
||||
|
||||
#include <rpc/xdr.h> /* xdrstdio_create() */
|
||||
#include <stdint.h> /* UINT32_MAX */
|
||||
#include <stdio.h> /* fopen() */
|
||||
#include <string.h> /* memset() */
|
||||
#include <stdio.h>
|
||||
#include <stdint.h>
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
|
||||
#include <rpc/xdr.h>
|
||||
|
||||
#include "guestfs.h" /* guestfs_internal_readdir() */
|
||||
#include "guestfs_protocol.h" /* guestfs_int_dirent */
|
||||
|
||||
Reference in New Issue
Block a user