bdev: include own getline function in bdev.h

Fixes android build error: bdev/bdev.c: In function 'detect_fs': bdev/bdev.c:686:2: error: implicit declaration of function 'getline' [-Werror=implicit-function-declaration] while (getline(&line, &linelen, f) != -1) { ^ Signed-off-by: 's avatarChristian Brauner <cbrauner@suse.de>
parent 813d7f14
......@@ -33,6 +33,13 @@
#include "config.h"
/* Define getline() if missing from the C library */
#ifndef HAVE_GETLINE
#ifdef HAVE_FGETLN
#include <../../include/getline.h>
#endif
#endif
/* define constants if the kernel/glibc headers don't define them */
#ifndef MS_DIRSYNC
#define MS_DIRSYNC 128
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment