From d8a82b088b4b3816dc7e7b91bac149e34ea2c45b Mon Sep 17 00:00:00 2001 From: Kaz Kylheku Date: Tue, 31 May 2022 01:56:00 -0700 Subject: gzio: fix multiple definition of gzio_stream_s. Failed on Cygwin. * gzio.c (gzio_stream_s): Variable defined here. * gzio.h (gzio_stream_s): Turn to declaration with extern. --- gzio.c | 2 ++ gzio.h | 2 +- 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/gzio.c b/gzio.c index 2485201a..bbdc1d45 100644 --- a/gzio.c +++ b/gzio.c @@ -61,6 +61,8 @@ struct gzio_handle { unsigned is_output : 8; }; +val gzio_stream_s; + struct cobj_class *gzio_stream_cls; static void gzio_stream_print(val stream, val out, val pretty, diff --git a/gzio.h b/gzio.h index 2f9cf164..4b5e9ee9 100644 --- a/gzio.h +++ b/gzio.h @@ -26,7 +26,7 @@ * POSSIBILITY OF SUCH DAMAGE. */ -val gzio_stream_s; +extern val gzio_stream_s; void gzio_init(void); gzFile w_gzopen_mode(const wchar_t *wname, const wchar_t *wmode, const struct stdio_mode m, val self); -- cgit v1.2.3