summaryrefslogtreecommitdiffstats
path: root/lib/consoles.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/consoles.c')
-rw-r--r--lib/consoles.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/lib/consoles.c b/lib/consoles.c
index 2e9793f0e..bc7c039bd 100644
--- a/lib/consoles.c
+++ b/lib/consoles.c
@@ -170,13 +170,6 @@ char* scandev(DIR *dir, dev_t comparedev)
/*
* Default control characters for an unknown terminal line.
*/
-static
-struct chardata initcp = {
- CERASE,
- CKILL,
- CTRL('r'),
- 0
-};
/*
* Allocate an aligned `struct console' memory area,
@@ -192,8 +185,15 @@ __attribute__((__nonnull__,__hot__))
#endif
void consalloc(char * name)
{
+ static const struct chardata initcp = {
+ .erase = CERASE,
+ .kill = CKILL,
+ .eol = CTRL('r'),
+ .parity = 0
+ };
struct console *restrict tail;
+
if (posix_memalign((void*)&tail, sizeof(void*), alignof(typeof(struct console))) != 0)
perror("memory allocation");