Fix obscure C stdio bug
[projects/chimara/chimara.git] / libchimara / stream.h
index 1e5a720b141469fa54c46b654bdaeec276af7793..325b668bb22c96527b3199af9ee892342d875113 100644 (file)
@@ -2,6 +2,7 @@
 #define STREAM_H
 
 #include <gtk/gtk.h>
+#include "chimara-glk-private.h"
 #include "glk.h"
 #include "gi_dispa.h"
 #include "window.h"
@@ -47,9 +48,11 @@ struct glk_stream_struct
        FILE *file_pointer;
        gboolean binary;
        gchar *filename; /* Displayable filename in UTF-8 for error handling */
+       glui32 lastop; /* 0, filemode_Write, or filemode_Read */
 
        gchar *style; /* Name of the current style */
-       gboolean hyperlink_mode; /* WHen turned on, text written to the stream will be a hyperlink */
+       gchar *glk_style; /* Name of the current glk style override */
+       gboolean hyperlink_mode; /* When turned on, text written to the stream will be a hyperlink */
 };
 
 G_GNUC_INTERNAL strid_t file_stream_new(frefid_t fileref, glui32 fmode, glui32 rock, gboolean unicode);