Skip to content

Commit b98d3c6

Browse files
committed
Fix c_cc field definition
c_cc is not an array of Cc members. The Cc enum are the index positions. The value at a given index position is an arbitrary byte value.
1 parent fc14ea3 commit b98d3c6

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

lib/std/libc/os/linux.c3

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -256,7 +256,7 @@ constdef Speed : CUInt
256256
MAX_BAUD = B4000000,
257257
}
258258

259-
constdef Cc : inline char
259+
constdef Control_Char : inline CInt
260260
{
261261
VINTR = 0,
262262
VQUIT = 1,
@@ -302,7 +302,10 @@ extern fn Speed cfgetispeed(Termios* self);
302302
extern fn CInt cfsetospeed(Termios* self, Speed speed);
303303
extern fn CInt cfsetispeed(Termios* self, Speed speed);
304304

305+
alias Cc = char;
306+
305307
const CInt NCCS = 32;
308+
306309
struct Termios
307310
{
308311
Tc_iflags c_iflag;

0 commit comments

Comments
 (0)