summaryrefslogtreecommitdiffstats
path: root/generic/tclIO.h
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2023-09-25 08:51:37 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2023-09-25 08:51:37 (GMT)
commit1c2359595d2d7376f8a7c36c81a0736dcf5390a3 (patch)
treed40e636ccf6851858d879d694d3c6889a2696395 /generic/tclIO.h
parentfa3868a2a6dfe5003e5c2c78f6f2d1a232d767a2 (diff)
downloadtcl-1c2359595d2d7376f8a7c36c81a0736dcf5390a3.zip
tcl-1c2359595d2d7376f8a7c36c81a0736dcf5390a3.tar.gz
tcl-1c2359595d2d7376f8a7c36c81a0736dcf5390a3.tar.bz2
Move CHANNEL_*BUFFERED (internal) flags to higher bits: prevent any possibility for conflicts with public flags TCL_ENCODING_STOPONERROR|TCL_ENCODING_NO_TERMINATE|TCL_ENCODING_CHAR_LIMIT
Diffstat (limited to 'generic/tclIO.h')
-rw-r--r--generic/tclIO.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/generic/tclIO.h b/generic/tclIO.h
index 729db5d..08fff44 100644
--- a/generic/tclIO.h
+++ b/generic/tclIO.h
@@ -158,8 +158,10 @@ typedef struct ChannelState {
* of line sequences in output? */
int inEofChar; /* If nonzero, use this as a signal of EOF on
* input. */
+#if TCL_MAJOR_VERSION < 9
int outEofChar; /* If nonzero, append this to the channel when
- * it is closed if it is open for writing. */
+ * it is closed if it is open for writing. For Tcl 8.x only */
+#endif
int unreportedError; /* Non-zero if an error report was deferred
* because it happened in the background. The
* value is the POSIX error code. */
@@ -230,12 +232,8 @@ typedef struct ChannelState {
* the channel can also have TCL_READABLE (1<<1) and TCL_WRITABLE (1<<2) set.
*/
-#define CHANNEL_NONBLOCKING (1<<3) /* Channel is currently in nonblocking
+#define CHANNEL_NONBLOCKING (1<<6) /* Channel is currently in nonblocking
* mode. */
-#define CHANNEL_LINEBUFFERED (1<<4) /* Output to the channel must be
- * flushed after every newline. */
-#define CHANNEL_UNBUFFERED (1<<5) /* Output to the channel must always
- * be flushed immediately. */
#define BG_FLUSH_SCHEDULED (1<<7) /* A background flush of the queued
* output buffers has been
* scheduled. */
@@ -278,6 +276,10 @@ typedef struct ChannelState {
* encountered an encoding error */
#define CHANNEL_RAW_MODE (1<<16) /* When set, notes that the Raw API is
* being used. */
+#define CHANNEL_LINEBUFFERED (1<<17) /* Output to the channel must be
+ * flushed after every newline. */
+#define CHANNEL_UNBUFFERED (1<<18) /* Output to the channel must always
+ * be flushed immediately. */
#define CHANNEL_INCLOSE (1<<19) /* Channel is currently being closed.
* Its structures are still live and
* usable, but it may not be closed