aboutsummaryrefslogtreecommitdiffstats
path: root/src/input_stream.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/input_stream.h')
-rw-r--r--src/input_stream.h14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/input_stream.h b/src/input_stream.h
index 35b0d44fd..a617632a0 100644
--- a/src/input_stream.h
+++ b/src/input_stream.h
@@ -20,11 +20,17 @@
#ifndef MPD_INPUT_STREAM_H
#define MPD_INPUT_STREAM_H
+#include "check.h"
+
+#include <glib.h>
+
#include <stddef.h>
#include <stdbool.h>
#include <sys/types.h>
-struct input_stream;
+#if !GLIB_CHECK_VERSION(2,14,0)
+typedef gint64 goffset;
+#endif
struct input_stream {
/**
@@ -56,12 +62,12 @@ struct input_stream {
/**
* the size of the resource, or -1 if unknown
*/
- off_t size;
+ goffset size;
/**
* the current offset within the stream
*/
- off_t offset;
+ goffset offset;
/**
* the MIME content type of the resource, or NULL if unknown
@@ -106,7 +112,7 @@ input_stream_close(struct input_stream *is);
* @param whence the base of the seek, one of SEEK_SET, SEEK_CUR, SEEK_END
*/
bool
-input_stream_seek(struct input_stream *is, off_t offset, int whence);
+input_stream_seek(struct input_stream *is, goffset offset, int whence);
/**
* Returns true if the stream has reached end-of-file.